Class: WhopSDK::Models::PlanCalculateTaxResponse
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- WhopSDK::Models::PlanCalculateTaxResponse
- Defined in:
- lib/whop_sdk/models/plan_calculate_tax_response.rb,
sig/whop_sdk/models/plan_calculate_tax_response.rbs
Overview
Defined Under Namespace
Modules: Status, TaxBehavior
Instance Attribute Summary collapse
-
#currency ⇒ String
Three-letter ISO 4217 currency code for the returned amounts.
-
#status ⇒ Symbol, WhopSDK::Models::PlanCalculateTaxResponse::Status
Whether Whop calculated tax for this preview.
-
#subtotal ⇒ Integer
Plan price in the currency's smallest unit, for example cents.
-
#tax_amount ⇒ Integer
Calculated tax amount in the currency's smallest unit.
-
#tax_behavior ⇒ Symbol, WhopSDK::Models::PlanCalculateTaxResponse::TaxBehavior
Whether tax is added on top of the plan price or already included in it for this buyer's location.
-
#total ⇒ Integer
Amount the buyer would pay in the currency's smallest unit.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(currency:, status:, subtotal:, tax_amount:, tax_behavior:, total:) ⇒ Object
constructor
Some parameter documentations has been truncated, see PlanCalculateTaxResponse for more details.
- #to_hash ⇒ {
Methods inherited from Internal::Type::BaseModel
==, #==, #[], 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
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(currency:, status:, subtotal:, tax_amount:, tax_behavior:, total:) ⇒ Object
Some parameter documentations has been truncated, see WhopSDK::Models::PlanCalculateTaxResponse for more details.
|
|
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 49
|
Instance Attribute Details
#currency ⇒ String
Three-letter ISO 4217 currency code for the returned amounts.
11 |
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 11 required :currency, String |
#status ⇒ Symbol, WhopSDK::Models::PlanCalculateTaxResponse::Status
Whether Whop calculated tax for this preview. not_calculated means no tax
could be determined, so tax_amount is 0 and total equals subtotal.
18 |
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 18 required :status, enum: -> { WhopSDK::Models::PlanCalculateTaxResponse::Status } |
#subtotal ⇒ Integer
Plan price in the currency's smallest unit, for example cents. For exclusive tax, this is the pre-tax amount; for inclusive tax, it already includes tax and equals the total.
26 |
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 26 required :subtotal, Integer |
#tax_amount ⇒ Integer
Calculated tax amount in the currency's smallest unit. For exclusive tax, this is added on top of the subtotal; for inclusive tax, it is the portion of the subtotal that is tax.
34 |
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 34 required :tax_amount, Integer |
#tax_behavior ⇒ Symbol, WhopSDK::Models::PlanCalculateTaxResponse::TaxBehavior
Whether tax is added on top of the plan price or already included in it for this buyer's location.
41 |
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 41 required :tax_behavior, enum: -> { WhopSDK::Models::PlanCalculateTaxResponse::TaxBehavior } |
#total ⇒ Integer
Amount the buyer would pay in the currency's smallest unit.
47 |
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 47 required :total, Integer |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/whop_sdk/models/plan_calculate_tax_response.rb', line 75
|
Instance Method Details
#to_hash ⇒ {
35 |
# File 'sig/whop_sdk/models/plan_calculate_tax_response.rbs', line 35
def to_hash: -> {
|