Class: GrowsurfRuby::Models::Campaign::RewardUpdateParams
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- GrowsurfRuby::Models::Campaign::RewardUpdateParams
- Extended by:
- Internal::Type::RequestParameters::Converter
- Includes:
- Internal::Type::RequestParameters
- Defined in:
- lib/growsurf_ruby/models/campaign/reward_update_params.rb,
sig/growsurf_ruby/models/campaign/reward_update_params.rbs
Overview
Defined Under Namespace
Modules: Event, LimitDuration
Constant Summary collapse
- GrowsurfRuby =
Instance Attribute Summary collapse
- #campaign_reward_id ⇒ String
- #commission_structure ⇒ GrowsurfRuby::Models::CommissionStructure?
- #conversions_required ⇒ Integer?
-
#coupon_code ⇒ String?
Legacy static coupon code shown to the referrer in the reward-won email and webhook.
- #description ⇒ String?
-
#event ⇒ Symbol, ...
The referral event that earns this Campaign Reward.
- #id ⇒ String
- #image_url ⇒ String?
-
#is_unlimited ⇒ Boolean?
Whether the reward can be earned an unlimited number of times.
-
#is_visible ⇒ Boolean?
Whether the reward is enabled.
- #limit ⇒ Integer?
- #limit_duration ⇒ Symbol, ...
-
#metadata ⇒ Hash{Symbol=>Object}?
Custom key/value metadata (single-level; values are stored as strings).
-
#next_milestone_prefix ⇒ String?
Text shown before a participant's referral count in milestone-progress copy.
-
#next_milestone_suffix ⇒ String?
Text shown after a participant's referral count in milestone-progress copy.
-
#number_of_winners ⇒ Integer?
The number of winners (
LEADERBOARDrewards only). - #order ⇒ Integer?
-
#referral_coupon_code ⇒ String?
Legacy static coupon code shown to the referred friend (double-sided rewards) in the reward-won email and webhook.
- #referral_description ⇒ String?
- #referred_reward_upfront ⇒ Boolean?
-
#referred_value ⇒ GrowsurfRuby::Models::RewardTaxValuation?
Tax treatment override for the referred friend's side of a double-sided reward.
- #title ⇒ String?
-
#value ⇒ GrowsurfRuby::Models::RewardTaxValuation?
Tax valuation for the reward (the referrer's side of a double-sided reward).
Attributes included from Internal::Type::RequestParameters
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(id:, campaign_reward_id:, commission_structure: nil, conversions_required: nil, coupon_code: nil, description: nil, event: nil, image_url: nil, is_unlimited: nil, is_visible: nil, limit: nil, limit_duration: nil, metadata: nil, next_milestone_prefix: nil, next_milestone_suffix: nil, number_of_winners: nil, order: nil, referral_coupon_code: nil, referral_description: nil, referred_reward_upfront: nil, referred_value: nil, title: nil, value: nil, request_options: {}) ⇒ Object
constructor
Some parameter documentations has been truncated, see RewardUpdateParams for more details.
- #to_hash ⇒ {
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(id:, campaign_reward_id:, commission_structure: nil, conversions_required: nil, coupon_code: nil, description: nil, event: nil, image_url: nil, is_unlimited: nil, is_visible: nil, limit: nil, limit_duration: nil, metadata: nil, next_milestone_prefix: nil, next_milestone_suffix: nil, number_of_winners: nil, order: nil, referral_coupon_code: nil, referral_description: nil, referred_reward_upfront: nil, referred_value: nil, title: nil, value: nil, request_options: {}) ⇒ Object
Some parameter documentations has been truncated, see GrowsurfRuby::Models::Campaign::RewardUpdateParams for more details.
|
|
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 160
|
Instance Attribute Details
#campaign_reward_id ⇒ String
19 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 19 required :campaign_reward_id, String |
#commission_structure ⇒ GrowsurfRuby::Models::CommissionStructure?
24 25 26 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 24 optional :commission_structure, -> { GrowsurfRuby::CommissionStructure }, api_name: :commissionStructure |
#conversions_required ⇒ Integer?
31 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 31 optional :conversions_required, Integer, api_name: :conversionsRequired |
#coupon_code ⇒ String?
Legacy static coupon code shown to the referrer in the reward-won email and webhook. Display text only; superseded by a connected billing integration's issued coupon when one exists.
39 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 39 optional :coupon_code, String, api_name: :couponCode |
#description ⇒ String?
44 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 44 optional :description, String |
#event ⇒ Symbol, ...
The referral event that earns this Campaign Reward. Use LEAD or
CONVERSION. LEAD requires the program installation's referralTrigger to
be CUSTOM. This field applies only to SINGLE_SIDED, DOUBLE_SIDED, and
MILESTONE rewards. When omitted, the stored event is preserved.
53 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 53 optional :event, enum: -> { GrowsurfRuby::Campaign::RewardUpdateParams::Event } |
#id ⇒ String
14 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 14 required :id, String |
#image_url ⇒ String?
58 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 58 optional :image_url, String, api_name: :imageUrl |
#is_unlimited ⇒ Boolean?
Whether the reward can be earned an unlimited number of times. Defaults to
true, except MILESTONE rewards, which can only be earned once.
65 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 65 optional :is_unlimited, GrowsurfRuby::Internal::Type::Boolean, api_name: :isUnlimited |
#is_visible ⇒ Boolean?
Whether the reward is enabled. When false the reward is disabled: hidden from
participants and no longer awarded, including those who already earned it.
72 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 72 optional :is_visible, GrowsurfRuby::Internal::Type::Boolean, api_name: :isVisible |
#limit ⇒ Integer?
77 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 77 optional :limit, Integer |
#limit_duration ⇒ Symbol, ...
82 83 84 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 82 optional :limit_duration, enum: -> { GrowsurfRuby::Campaign::RewardUpdateParams::LimitDuration }, api_name: :limitDuration |
#metadata ⇒ Hash{Symbol=>Object}?
Custom key/value metadata (single-level; values are stored as strings).
90 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 90 optional :metadata, GrowsurfRuby::Internal::Type::HashOf[GrowsurfRuby::Internal::Type::Unknown] |
#next_milestone_prefix ⇒ String?
Text shown before a participant's referral count in milestone-progress copy.
Applies to MILESTONE rewards.
97 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 97 optional :next_milestone_prefix, String, api_name: :nextMilestonePrefix |
#next_milestone_suffix ⇒ String?
Text shown after a participant's referral count in milestone-progress copy.
Applies to MILESTONE rewards.
104 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 104 optional :next_milestone_suffix, String, api_name: :nextMilestoneSuffix |
#number_of_winners ⇒ Integer?
The number of winners (LEADERBOARD rewards only). With limitDuration
PER_MONTH this many win each month, otherwise this many win in total;
omitting it defaults to 3.
112 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 112 optional :number_of_winners, Integer, api_name: :numberOfWinners |
#order ⇒ Integer?
117 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 117 optional :order, Integer |
#referral_coupon_code ⇒ String?
Legacy static coupon code shown to the referred friend (double-sided rewards) in the reward-won email and webhook. Display text only; superseded by a connected billing integration's issued coupon when one exists.
125 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 125 optional :referral_coupon_code, String, api_name: :referralCouponCode |
#referral_description ⇒ String?
130 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 130 optional :referral_description, String, api_name: :referralDescription |
#referred_reward_upfront ⇒ Boolean?
135 136 137 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 135 optional :referred_reward_upfront, GrowsurfRuby::Internal::Type::Boolean, api_name: :referredRewardUpfront |
#referred_value ⇒ GrowsurfRuby::Models::RewardTaxValuation?
Tax treatment override for the referred friend's side of a double-sided reward. Defaults to the program's confirmed default.
144 145 146 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 144 optional :referred_value, -> { GrowsurfRuby::RewardTaxValuation }, api_name: :referredValue |
#title ⇒ String?
151 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 151 optional :title, String |
#value ⇒ GrowsurfRuby::Models::RewardTaxValuation?
Tax valuation for the reward (the referrer's side of a double-sided reward). Used by tax documentation / 1099 reporting.
158 |
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 158 optional :value, -> { GrowsurfRuby::RewardTaxValuation } |
Class Method Details
.values ⇒ Array<Symbol>
|
|
# File 'lib/growsurf_ruby/models/campaign/reward_update_params.rb', line 219
|
Instance Method Details
#to_hash ⇒ {
161 |
# File 'sig/growsurf_ruby/models/campaign/reward_update_params.rbs', line 161
def to_hash: -> {
|