Class: WhopSDK::Models::CheckoutConfigurationCreateParams::Plan
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- WhopSDK::Models::CheckoutConfigurationCreateParams::Plan
- Defined in:
- lib/whop_sdk/models/checkout_configuration_create_params.rb
Defined Under Namespace
Classes: CustomField, Image
Instance Attribute Summary collapse
-
#billing_period ⇒ Integer?
The interval at which the plan charges (renewal plans).
-
#company_id ⇒ String
The company the plan should be created for.
-
#currency ⇒ Symbol, ...
The available currencies on the platform.
-
#custom_fields ⇒ Array<WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::CustomField>?
An array of custom field objects.
-
#description ⇒ String?
The description of the plan.
-
#expiration_days ⇒ Integer?
The interval at which the plan charges (expiration plans).
-
#force_create_new_plan ⇒ Boolean?
Whether to force the creation of a new plan even if one with the same attributes already exists.
-
#image ⇒ WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::Image?
An image for the plan.
-
#initial_price ⇒ Float?
An additional amount charged upon first purchase.
-
#internal_notes ⇒ String?
A personal description or notes section for the business.
-
#override_tax_type ⇒ Symbol, ...
Whether or not the tax is included in a plan’s price (or if it hasn’t been set up).
-
#plan_type ⇒ Symbol, ...
The type of plan that can be attached to an access pass.
-
#product_id ⇒ String?
The product the plan is related to.
-
#release_method ⇒ Symbol, ...
The methods of how a plan can be released.
-
#renewal_price ⇒ Float?
The amount the customer is charged every billing period.
-
#title ⇒ String?
The title of the plan.
-
#trial_period_days ⇒ Integer?
The number of free trial days added before a renewal plan.
-
#visibility ⇒ Symbol, ...
Visibility of a resource.
Instance Method Summary collapse
- #initialize(name: , id: nil, order: nil, placeholder: nil, required: nil, field_type: :text) ⇒ Object constructor
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(name: , id: nil, order: nil, placeholder: nil, required: nil, field_type: :text) ⇒ Object
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 53 class Plan < WhopSDK::Internal::Type::BaseModel # @!attribute company_id # The company the plan should be created for. # # @return [String] required :company_id, String # @!attribute billing_period # The interval at which the plan charges (renewal plans). # # @return [Integer, nil] optional :billing_period, Integer, nil?: true # @!attribute currency # The available currencies on the platform # # @return [Symbol, WhopSDK::Models::Currency, nil] optional :currency, enum: -> { WhopSDK::Currency }, nil?: true # @!attribute custom_fields # An array of custom field objects. # # @return [Array<WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::CustomField>, nil] optional :custom_fields, -> { WhopSDK::Internal::Type::ArrayOf[WhopSDK::CheckoutConfigurationCreateParams::Plan::CustomField] }, nil?: true # @!attribute description # The description of the plan. # # @return [String, nil] optional :description, String, nil?: true # @!attribute expiration_days # The interval at which the plan charges (expiration plans). # # @return [Integer, nil] optional :expiration_days, Integer, nil?: true # @!attribute force_create_new_plan # Whether to force the creation of a new plan even if one with the same attributes # already exists. # # @return [Boolean, nil] optional :force_create_new_plan, WhopSDK::Internal::Type::Boolean, nil?: true # @!attribute image # An image for the plan. This will be visible on the product page to customers. # # @return [WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::Image, nil] optional :image, -> { WhopSDK::CheckoutConfigurationCreateParams::Plan::Image }, nil?: true # @!attribute initial_price # An additional amount charged upon first purchase. # # @return [Float, nil] optional :initial_price, Float, nil?: true # @!attribute internal_notes # A personal description or notes section for the business. # # @return [String, nil] optional :internal_notes, String, nil?: true # @!attribute override_tax_type # Whether or not the tax is included in a plan's price (or if it hasn't been set # up) # # @return [Symbol, WhopSDK::Models::TaxType, nil] optional :override_tax_type, enum: -> { WhopSDK::TaxType }, nil?: true # @!attribute plan_type # The type of plan that can be attached to an access pass # # @return [Symbol, WhopSDK::Models::PlanType, nil] optional :plan_type, enum: -> { WhopSDK::PlanType }, nil?: true # @!attribute product_id # The product the plan is related to. # # @return [String, nil] optional :product_id, String, nil?: true # @!attribute release_method # The methods of how a plan can be released. # # @return [Symbol, WhopSDK::Models::ReleaseMethod, nil] optional :release_method, enum: -> { WhopSDK::ReleaseMethod }, nil?: true # @!attribute renewal_price # The amount the customer is charged every billing period. # # @return [Float, nil] optional :renewal_price, Float, nil?: true # @!attribute title # The title of the plan. This will be visible on the product page to customers. # # @return [String, nil] optional :title, String, nil?: true # @!attribute trial_period_days # The number of free trial days added before a renewal plan. # # @return [Integer, nil] optional :trial_period_days, Integer, nil?: true # @!attribute visibility # Visibility of a resource # # @return [Symbol, WhopSDK::Models::Visibility, nil] optional :visibility, enum: -> { WhopSDK::Visibility }, nil?: true # @!method initialize(company_id:, billing_period: nil, currency: nil, custom_fields: nil, description: nil, expiration_days: nil, force_create_new_plan: nil, image: nil, initial_price: nil, internal_notes: nil, override_tax_type: nil, plan_type: nil, product_id: nil, release_method: nil, renewal_price: nil, title: nil, trial_period_days: nil, visibility: nil) # Some parameter documentations has been truncated, see # {WhopSDK::Models::CheckoutConfigurationCreateParams::Plan} for more details. # # Pass this object to create a new plan for this checkout configuration # # @param company_id [String] The company the plan should be created for. # # @param billing_period [Integer, nil] The interval at which the plan charges (renewal plans). # # @param currency [Symbol, WhopSDK::Models::Currency, nil] The available currencies on the platform # # @param custom_fields [Array<WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::CustomField>, nil] An array of custom field objects. # # @param description [String, nil] The description of the plan. # # @param expiration_days [Integer, nil] The interval at which the plan charges (expiration plans). # # @param force_create_new_plan [Boolean, nil] Whether to force the creation of a new plan even if one with the same attributes # # @param image [WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::Image, nil] An image for the plan. This will be visible on the product page to customers. # # @param initial_price [Float, nil] An additional amount charged upon first purchase. # # @param internal_notes [String, nil] A personal description or notes section for the business. # # @param override_tax_type [Symbol, WhopSDK::Models::TaxType, nil] Whether or not the tax is included in a plan's price (or if it hasn't been set u # # @param plan_type [Symbol, WhopSDK::Models::PlanType, nil] The type of plan that can be attached to an access pass # # @param product_id [String, nil] The product the plan is related to. # # @param release_method [Symbol, WhopSDK::Models::ReleaseMethod, nil] The methods of how a plan can be released. # # @param renewal_price [Float, nil] The amount the customer is charged every billing period. # # @param title [String, nil] The title of the plan. This will be visible on the product page to customers. # # @param trial_period_days [Integer, nil] The number of free trial days added before a renewal plan. # # @param visibility [Symbol, WhopSDK::Models::Visibility, nil] Visibility of a resource class CustomField < WhopSDK::Internal::Type::BaseModel # @!attribute field_type # The type of the custom field. # # @return [Symbol, :text] required :field_type, const: :text # @!attribute name # The name of the custom field. # # @return [String] required :name, String # @!attribute id # The ID of the custom field (if being updated) # # @return [String, nil] optional :id, String, nil?: true # @!attribute order # The order of the field. # # @return [Integer, nil] optional :order, Integer, nil?: true # @!attribute placeholder # The placeholder value of the field. # # @return [String, nil] optional :placeholder, String, nil?: true # @!attribute required # Whether or not the field is required. # # @return [Boolean, nil] optional :required, WhopSDK::Internal::Type::Boolean, nil?: true # @!method initialize(name:, id: nil, order: nil, placeholder: nil, required: nil, field_type: :text) # @param name [String] The name of the custom field. # # @param id [String, nil] The ID of the custom field (if being updated) # # @param order [Integer, nil] The order of the field. # # @param placeholder [String, nil] The placeholder value of the field. # # @param required [Boolean, nil] Whether or not the field is required. # # @param field_type [Symbol, :text] The type of the custom field. end # @see WhopSDK::Models::CheckoutConfigurationCreateParams::Plan#image class Image < WhopSDK::Internal::Type::BaseModel # @!attribute id # The ID of an existing attachment object. Use this when updating a resource and # keeping a subset of the attachments. Don't use this unless you know what you're # doing. # # @return [String, nil] optional :id, String, nil?: true # @!attribute direct_upload_id # This ID should be used the first time you upload an attachment. It is the ID of # the direct upload that was created when uploading the file to S3 via the # mediaDirectUpload mutation. # # @return [String, nil] optional :direct_upload_id, String, nil?: true # @!method initialize(id: nil, direct_upload_id: nil) # Some parameter documentations has been truncated, see # {WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::Image} for more # details. # # An image for the plan. This will be visible on the product page to customers. # # @param id [String, nil] The ID of an existing attachment object. Use this when updating a resource and k # # @param direct_upload_id [String, nil] This ID should be used the first time you upload an attachment. It is the ID of end end |
Instance Attribute Details
#billing_period ⇒ Integer?
The interval at which the plan charges (renewal plans).
64 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 64 optional :billing_period, Integer, nil?: true |
#company_id ⇒ String
The company the plan should be created for.
58 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 58 required :company_id, String |
#currency ⇒ Symbol, ...
The available currencies on the platform
70 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 70 optional :currency, enum: -> { WhopSDK::Currency }, nil?: true |
#custom_fields ⇒ Array<WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::CustomField>?
An array of custom field objects.
76 77 78 79 80 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 76 optional :custom_fields, -> { WhopSDK::Internal::Type::ArrayOf[WhopSDK::CheckoutConfigurationCreateParams::Plan::CustomField] }, nil?: true |
#description ⇒ String?
The description of the plan.
86 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 86 optional :description, String, nil?: true |
#expiration_days ⇒ Integer?
The interval at which the plan charges (expiration plans).
92 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 92 optional :expiration_days, Integer, nil?: true |
#force_create_new_plan ⇒ Boolean?
Whether to force the creation of a new plan even if one with the same attributes already exists.
99 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 99 optional :force_create_new_plan, WhopSDK::Internal::Type::Boolean, nil?: true |
#image ⇒ WhopSDK::Models::CheckoutConfigurationCreateParams::Plan::Image?
An image for the plan. This will be visible on the product page to customers.
105 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 105 optional :image, -> { WhopSDK::CheckoutConfigurationCreateParams::Plan::Image }, nil?: true |
#initial_price ⇒ Float?
An additional amount charged upon first purchase.
111 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 111 optional :initial_price, Float, nil?: true |
#internal_notes ⇒ String?
A personal description or notes section for the business.
117 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 117 optional :internal_notes, String, nil?: true |
#override_tax_type ⇒ Symbol, ...
Whether or not the tax is included in a plan’s price (or if it hasn’t been set up)
124 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 124 optional :override_tax_type, enum: -> { WhopSDK::TaxType }, nil?: true |
#plan_type ⇒ Symbol, ...
The type of plan that can be attached to an access pass
130 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 130 optional :plan_type, enum: -> { WhopSDK::PlanType }, nil?: true |
#product_id ⇒ String?
The product the plan is related to.
136 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 136 optional :product_id, String, nil?: true |
#release_method ⇒ Symbol, ...
The methods of how a plan can be released.
142 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 142 optional :release_method, enum: -> { WhopSDK::ReleaseMethod }, nil?: true |
#renewal_price ⇒ Float?
The amount the customer is charged every billing period.
148 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 148 optional :renewal_price, Float, nil?: true |
#title ⇒ String?
The title of the plan. This will be visible on the product page to customers.
154 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 154 optional :title, String, nil?: true |
#trial_period_days ⇒ Integer?
The number of free trial days added before a renewal plan.
160 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 160 optional :trial_period_days, Integer, nil?: true |
#visibility ⇒ Symbol, ...
Visibility of a resource
166 |
# File 'lib/whop_sdk/models/checkout_configuration_create_params.rb', line 166 optional :visibility, enum: -> { WhopSDK::Visibility }, nil?: true |