Class: Stripe::Checkout::SessionService::CreateParams::SavedPaymentMethodOptions

Inherits:
RequestParams
  • Object
show all
Defined in:
lib/stripe/services/checkout/session_service.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from RequestParams

#to_h

Constructor Details

#initialize(allow_redisplay_filters: nil, payment_method_remove: nil, payment_method_save: nil) ⇒ SavedPaymentMethodOptions

Returns a new instance of SavedPaymentMethodOptions.



1819
1820
1821
1822
1823
1824
1825
1826
1827
# File 'lib/stripe/services/checkout/session_service.rb', line 1819

def initialize(
  allow_redisplay_filters: nil,
  payment_method_remove: nil,
  payment_method_save: nil
)
  @allow_redisplay_filters = allow_redisplay_filters
  @payment_method_remove = payment_method_remove
  @payment_method_save = payment_method_save
end

Instance Attribute Details

#allow_redisplay_filtersObject

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.



1813
1814
1815
# File 'lib/stripe/services/checkout/session_service.rb', line 1813

def allow_redisplay_filters
  @allow_redisplay_filters
end

#payment_method_removeObject

Enable customers to choose if they wish to remove their saved payment methods. Disabled by default.



1815
1816
1817
# File 'lib/stripe/services/checkout/session_service.rb', line 1815

def payment_method_remove
  @payment_method_remove
end

#payment_method_saveObject

Enable customers to choose if they wish to save their payment method for future use. Disabled by default.



1817
1818
1819
# File 'lib/stripe/services/checkout/session_service.rb', line 1817

def payment_method_save
  @payment_method_save
end