Class: WhopSDK::Models::CheckoutConfiguration::Plan

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/whop_sdk/models/checkout_configuration.rb

Overview

See Also:

Instance Attribute Summary collapse

Instance Method Summary collapse

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(id: , billing_period: , currency: , expiration_days: , initial_price: , plan_type: , release_method: , renewal_price: , trial_period_days: , visibility: ) ⇒ Object

The plan to use for the checkout configuration

Parameters:

  • id (String) (defaults to: )

    The internal ID of the plan.

  • billing_period (Integer, nil) (defaults to: )

    The interval at which the plan charges (renewal plans).

  • currency (Symbol, WhopSDK::Models::Currency) (defaults to: )

    The respective currency identifier for the plan.

  • expiration_days (Integer, nil) (defaults to: )

    The interval at which the plan charges (expiration plans).

  • initial_price (Float) (defaults to: )

    The price a person has to pay for a plan on the initial purchase.

  • plan_type (Symbol, WhopSDK::Models::PlanType) (defaults to: )

    Indicates if the plan is a one time payment or recurring.

  • release_method (Symbol, WhopSDK::Models::ReleaseMethod) (defaults to: )

    This is the release method the business uses to sell this plan.

  • renewal_price (Float) (defaults to: )

    The price a person has to pay for a plan on the renewal purchase.

  • trial_period_days (Integer, nil) (defaults to: )

    The number of free trial days added before a renewal plan.

  • visibility (Symbol, WhopSDK::Models::Visibility) (defaults to: )

    Shows or hides the plan from public/business view.



# File 'lib/whop_sdk/models/checkout_configuration.rb', line 134

Instance Attribute Details

#billing_periodInteger?

The interval at which the plan charges (renewal plans).

Returns:

  • (Integer, nil)


84
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 84

required :billing_period, Integer, nil?: true

#currencySymbol, WhopSDK::Models::Currency

The respective currency identifier for the plan.

Returns:



90
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 90

required :currency, enum: -> { WhopSDK::Currency }

#expiration_daysInteger?

The interval at which the plan charges (expiration plans).

Returns:

  • (Integer, nil)


96
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 96

required :expiration_days, Integer, nil?: true

#idString

The internal ID of the plan.

Returns:

  • (String)


78
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 78

required :id, String

#initial_priceFloat

The price a person has to pay for a plan on the initial purchase.

Returns:

  • (Float)


102
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 102

required :initial_price, Float

#plan_typeSymbol, WhopSDK::Models::PlanType

Indicates if the plan is a one time payment or recurring.

Returns:



108
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 108

required :plan_type, enum: -> { WhopSDK::PlanType }

#release_methodSymbol, WhopSDK::Models::ReleaseMethod

This is the release method the business uses to sell this plan.

Returns:



114
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 114

required :release_method, enum: -> { WhopSDK::ReleaseMethod }

#renewal_priceFloat

The price a person has to pay for a plan on the renewal purchase.

Returns:

  • (Float)


120
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 120

required :renewal_price, Float

#trial_period_daysInteger?

The number of free trial days added before a renewal plan.

Returns:

  • (Integer, nil)


126
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 126

required :trial_period_days, Integer, nil?: true

#visibilitySymbol, WhopSDK::Models::Visibility

Shows or hides the plan from public/business view.

Returns:



132
# File 'lib/whop_sdk/models/checkout_configuration.rb', line 132

required :visibility, enum: -> { WhopSDK::Visibility }