Class: Dodopayments::Models::CheckoutSessionPreviewResponse::ProductCart::Addon
- Inherits:
-
Internal::Type::BaseModel
show all
- Defined in:
- lib/dodopayments/models/checkout_session_preview_response.rb,
sig/dodopayments/models/checkout_session_preview_response.rbs
Instance Attribute Summary collapse
Instance Method Summary
collapse
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize ⇒ Object
338
|
# File 'sig/dodopayments/models/checkout_session_preview_response.rbs', line 338
def initialize: (
|
Instance Attribute Details
#addon_id ⇒ String
410
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 410
required :addon_id, String
|
415
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 415
required :currency, enum: -> { Dodopayments::Currency }
|
#description ⇒ String?
471
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 471
optional :description, String, nil?: true
|
#discount_amount ⇒ Integer?
Percentage rate (basis points) of the applicable percentage code; null for flat
codes (their deduction is og_price - discounted_price).
478
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 478
optional :discount_amount, Integer, nil?: true
|
#discounted_price ⇒ Integer
420
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 420
required :discounted_price, Integer
|
#name ⇒ String
425
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 425
required :name, String
|
430
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 430
required :og_currency, enum: -> { Dodopayments::Currency }
|
#og_price ⇒ Integer
435
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 435
required :og_price, Integer
|
#quantity ⇒ Integer
440
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 440
required :quantity, Integer
|
#single_quantity_price ⇒ Integer
Per-unit price in currency, converted and adaptive-priced but pre-tax and
pre-discount (both depend on quantity and the rest of the cart). Set even when
quantity is 0, so the checkout page can price the addon before the buyer has
selected any.
449
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 449
required :single_quantity_price, Integer
|
#tax ⇒ Integer?
483
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 483
optional :tax, Integer, nil?: true
|
Represents the different categories of taxation applicable to various products
and services.
456
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 456
required :tax_category, enum: -> { Dodopayments::TaxCategory }
|
#tax_inclusive ⇒ Boolean
461
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 461
required :tax_inclusive, Dodopayments::Internal::Type::Boolean
|
#tax_rate ⇒ Integer
466
|
# File 'lib/dodopayments/models/checkout_session_preview_response.rb', line 466
required :tax_rate, Integer
|
Instance Method Details
#to_hash ⇒ {
355
|
# File 'sig/dodopayments/models/checkout_session_preview_response.rbs', line 355
def to_hash: -> {
|