Class: Onlyfans::Models::PromotionCreateParams
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Onlyfans::Models::PromotionCreateParams
- Extended by:
- Internal::Type::RequestParameters::Converter
- Includes:
- Internal::Type::RequestParameters
- Defined in:
- lib/onlyfans/models/promotion_create_params.rb
Overview
Defined Under Namespace
Modules: Type
Instance Attribute Summary collapse
- #account ⇒ String
-
#discount ⇒ Integer
The discount percentage for the promotion’s first month.
-
#expiration_days ⇒ Integer
In how many days this offer will expire.
-
#free_trial_days ⇒ Integer?
Required only when discount is 100.
-
#message ⇒ String?
Optionally, provide a message for this promotion.
-
#offer_limit ⇒ Integer
Limit how many people can claim this offer.
-
#type ⇒ Symbol, Onlyfans::Models::PromotionCreateParams::Type
Whether this promotion should apply to new subscribers, expired subscribers, or both.
Attributes included from Internal::Type::RequestParameters
Instance Method Summary collapse
-
#initialize(account:, discount:, expiration_days:, offer_limit:, type:, free_trial_days: nil, message: nil, request_options: {}) ⇒ Object
constructor
Some parameter documentations has been truncated, see PromotionCreateParams for more details.
Methods included from Internal::Type::RequestParameters::Converter
Methods included from Internal::Type::RequestParameters
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(account:, discount:, expiration_days:, offer_limit:, type:, free_trial_days: nil, message: nil, request_options: {}) ⇒ Object
Some parameter documentations has been truncated, see Onlyfans::Models::PromotionCreateParams for more details.
|
|
# File 'lib/onlyfans/models/promotion_create_params.rb', line 56
|
Instance Attribute Details
#account ⇒ String
13 |
# File 'lib/onlyfans/models/promotion_create_params.rb', line 13 required :account, String |
#discount ⇒ Integer
The discount percentage for the promotion’s first month. Set to 100 to make this promotion a Free Trial.
20 |
# File 'lib/onlyfans/models/promotion_create_params.rb', line 20 required :discount, Integer |
#expiration_days ⇒ Integer
In how many days this offer will expire. Set to 0 to make this promotion infinite.
27 |
# File 'lib/onlyfans/models/promotion_create_params.rb', line 27 required :expiration_days, Integer, api_name: :expirationDays |
#free_trial_days ⇒ Integer?
Required only when discount is 100. Sets the duration (in days) of the free trial. Accepted 1-30
48 |
# File 'lib/onlyfans/models/promotion_create_params.rb', line 48 optional :free_trial_days, Integer, api_name: :freeTrialDays |
#message ⇒ String?
Optionally, provide a message for this promotion.
54 |
# File 'lib/onlyfans/models/promotion_create_params.rb', line 54 optional :message, String |
#offer_limit ⇒ Integer
Limit how many people can claim this offer. Set to 0 for no limits.
33 |
# File 'lib/onlyfans/models/promotion_create_params.rb', line 33 required :offer_limit, Integer, api_name: :offerLimit |
#type ⇒ Symbol, Onlyfans::Models::PromotionCreateParams::Type
Whether this promotion should apply to new subscribers, expired subscribers, or both. **IMPORTANT: when set to new_and_expired, the OF will create two separate promotions.**
41 |
# File 'lib/onlyfans/models/promotion_create_params.rb', line 41 required :type, enum: -> { Onlyfans::PromotionCreateParams::Type } |