growsurf-ruby 0.7.0 → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +18 -0
- data/README.md +1 -1
- data/lib/growsurf_ruby/models/campaign/campaign_reward_list_response.rb +21 -0
- data/lib/growsurf_ruby/models/campaign/delete_reward_response.rb +26 -0
- data/lib/growsurf_ruby/models/campaign/reward.rb +193 -0
- data/lib/growsurf_ruby/models/campaign/reward_create_params.rb +212 -0
- data/lib/growsurf_ruby/models/campaign/reward_delete_params.rb +4 -4
- data/lib/growsurf_ruby/models/campaign/reward_update_params.rb +205 -0
- data/lib/growsurf_ruby/models/campaign.rb +28 -1
- data/lib/growsurf_ruby/models/campaign_create_params.rb +68 -0
- data/lib/growsurf_ruby/models/campaign_update_params.rb +63 -0
- data/lib/growsurf_ruby/models/reward_tax_valuation.rb +35 -0
- data/lib/growsurf_ruby/models.rb +6 -0
- data/lib/growsurf_ruby/resources/campaign/design.rb +66 -0
- data/lib/growsurf_ruby/resources/campaign/emails.rb +63 -0
- data/lib/growsurf_ruby/resources/campaign/installation.rb +65 -0
- data/lib/growsurf_ruby/resources/campaign/options.rb +63 -0
- data/lib/growsurf_ruby/resources/campaign/rewards.rb +199 -0
- data/lib/growsurf_ruby/resources/campaign.rb +112 -0
- data/lib/growsurf_ruby/version.rb +1 -1
- data/lib/growsurf_ruby.rb +13 -0
- data/rbi/growsurf_ruby/models/campaign/campaign_reward_list_response.rbi +41 -0
- data/rbi/growsurf_ruby/models/campaign/delete_reward_response.rbi +38 -0
- data/rbi/growsurf_ruby/models/campaign/reward.rbi +291 -0
- data/rbi/growsurf_ruby/models/campaign/reward_create_params.rbi +358 -0
- data/rbi/growsurf_ruby/models/campaign/reward_delete_params.rbi +4 -4
- data/rbi/growsurf_ruby/models/campaign/reward_update_params.rbi +309 -0
- data/rbi/growsurf_ruby/models/campaign.rbi +42 -3
- data/rbi/growsurf_ruby/models/campaign_create_params.rbi +125 -0
- data/rbi/growsurf_ruby/models/campaign_update_params.rbi +130 -0
- data/rbi/growsurf_ruby/models/reward_tax_valuation.rbi +56 -0
- data/rbi/growsurf_ruby/models.rbi +6 -0
- data/rbi/growsurf_ruby/resources/campaign/design.rbi +50 -0
- data/rbi/growsurf_ruby/resources/campaign/emails.rbi +49 -0
- data/rbi/growsurf_ruby/resources/campaign/installation.rbi +50 -0
- data/rbi/growsurf_ruby/resources/campaign/options.rbi +49 -0
- data/rbi/growsurf_ruby/resources/campaign/rewards.rbi +216 -0
- data/rbi/growsurf_ruby/resources/campaign.rbi +94 -0
- data/sig/growsurf_ruby/models/campaign/campaign_reward_list_response.rbs +18 -0
- data/sig/growsurf_ruby/models/campaign/delete_reward_response.rbs +17 -0
- data/sig/growsurf_ruby/models/campaign/reward.rbs +146 -0
- data/sig/growsurf_ruby/models/campaign/reward_create_params.rbs +210 -0
- data/sig/growsurf_ruby/models/campaign/reward_delete_params.rbs +4 -4
- data/sig/growsurf_ruby/models/campaign/reward_update_params.rbs +200 -0
- data/sig/growsurf_ruby/models/campaign.rbs +18 -3
- data/sig/growsurf_ruby/models/campaign_create_params.rbs +74 -0
- data/sig/growsurf_ruby/models/campaign_update_params.rbs +70 -0
- data/sig/growsurf_ruby/models/reward_tax_valuation.rbs +19 -0
- data/sig/growsurf_ruby/models.rbs +6 -0
- data/sig/growsurf_ruby/resources/campaign/design.rbs +20 -0
- data/sig/growsurf_ruby/resources/campaign/emails.rbs +20 -0
- data/sig/growsurf_ruby/resources/campaign/installation.rbs +20 -0
- data/sig/growsurf_ruby/resources/campaign/options.rbs +20 -0
- data/sig/growsurf_ruby/resources/campaign/rewards.rbs +74 -0
- data/sig/growsurf_ruby/resources/campaign.rbs +34 -0
- metadata +41 -2
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
module GrowsurfRuby
|
|
2
|
+
module Models
|
|
3
|
+
module Campaign
|
|
4
|
+
type reward =
|
|
5
|
+
{
|
|
6
|
+
id: String,
|
|
7
|
+
is_unlimited: bool,
|
|
8
|
+
metadata: ::Hash[Symbol, top],
|
|
9
|
+
type: GrowsurfRuby::Models::Campaign::Reward::type_,
|
|
10
|
+
commission_structure: GrowsurfRuby::CommissionStructure?,
|
|
11
|
+
conversions_required: Integer?,
|
|
12
|
+
coupon_code: String?,
|
|
13
|
+
description: String?,
|
|
14
|
+
image_url: String?,
|
|
15
|
+
limit: Integer?,
|
|
16
|
+
limit_duration: GrowsurfRuby::Models::Campaign::Reward::limit_duration?,
|
|
17
|
+
next_milestone_prefix: String?,
|
|
18
|
+
next_milestone_suffix: String?,
|
|
19
|
+
number_of_winners: Integer?,
|
|
20
|
+
order: Integer?,
|
|
21
|
+
referral_coupon_code: String?,
|
|
22
|
+
referral_description: String?,
|
|
23
|
+
referred_reward_upfront: bool,
|
|
24
|
+
referred_value: GrowsurfRuby::RewardTaxValuation?,
|
|
25
|
+
value: GrowsurfRuby::RewardTaxValuation?
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
class Reward < GrowsurfRuby::Internal::Type::BaseModel
|
|
29
|
+
attr_accessor id: String
|
|
30
|
+
|
|
31
|
+
attr_accessor is_unlimited: bool
|
|
32
|
+
|
|
33
|
+
attr_accessor metadata: ::Hash[Symbol, top]
|
|
34
|
+
|
|
35
|
+
attr_accessor type: GrowsurfRuby::Models::Campaign::Reward::type_
|
|
36
|
+
|
|
37
|
+
attr_accessor commission_structure: GrowsurfRuby::CommissionStructure?
|
|
38
|
+
|
|
39
|
+
attr_accessor conversions_required: Integer?
|
|
40
|
+
|
|
41
|
+
attr_accessor coupon_code: String?
|
|
42
|
+
|
|
43
|
+
attr_accessor description: String?
|
|
44
|
+
|
|
45
|
+
attr_accessor image_url: String?
|
|
46
|
+
|
|
47
|
+
attr_accessor limit: Integer?
|
|
48
|
+
|
|
49
|
+
attr_accessor limit_duration: GrowsurfRuby::Models::Campaign::Reward::limit_duration?
|
|
50
|
+
|
|
51
|
+
attr_accessor next_milestone_prefix: String?
|
|
52
|
+
|
|
53
|
+
attr_accessor next_milestone_suffix: String?
|
|
54
|
+
|
|
55
|
+
attr_accessor number_of_winners: Integer?
|
|
56
|
+
|
|
57
|
+
attr_accessor order: Integer?
|
|
58
|
+
|
|
59
|
+
attr_accessor referral_coupon_code: String?
|
|
60
|
+
|
|
61
|
+
attr_accessor referral_description: String?
|
|
62
|
+
|
|
63
|
+
attr_reader referred_reward_upfront: bool?
|
|
64
|
+
|
|
65
|
+
def referred_reward_upfront=: (bool) -> bool
|
|
66
|
+
|
|
67
|
+
attr_accessor referred_value: GrowsurfRuby::RewardTaxValuation?
|
|
68
|
+
|
|
69
|
+
attr_accessor value: GrowsurfRuby::RewardTaxValuation?
|
|
70
|
+
|
|
71
|
+
def initialize: (
|
|
72
|
+
id: String,
|
|
73
|
+
is_unlimited: bool,
|
|
74
|
+
metadata: ::Hash[Symbol, top],
|
|
75
|
+
type: GrowsurfRuby::Models::Campaign::Reward::type_,
|
|
76
|
+
?commission_structure: GrowsurfRuby::CommissionStructure?,
|
|
77
|
+
?conversions_required: Integer?,
|
|
78
|
+
?coupon_code: String?,
|
|
79
|
+
?description: String?,
|
|
80
|
+
?image_url: String?,
|
|
81
|
+
?limit: Integer?,
|
|
82
|
+
?limit_duration: GrowsurfRuby::Models::Campaign::Reward::limit_duration?,
|
|
83
|
+
?next_milestone_prefix: String?,
|
|
84
|
+
?next_milestone_suffix: String?,
|
|
85
|
+
?number_of_winners: Integer?,
|
|
86
|
+
?order: Integer?,
|
|
87
|
+
?referral_coupon_code: String?,
|
|
88
|
+
?referral_description: String?,
|
|
89
|
+
?referred_reward_upfront: bool,
|
|
90
|
+
?referred_value: GrowsurfRuby::RewardTaxValuation?,
|
|
91
|
+
?value: GrowsurfRuby::RewardTaxValuation?
|
|
92
|
+
) -> void
|
|
93
|
+
|
|
94
|
+
def to_hash: -> {
|
|
95
|
+
id: String,
|
|
96
|
+
is_unlimited: bool,
|
|
97
|
+
metadata: ::Hash[Symbol, top],
|
|
98
|
+
type: GrowsurfRuby::Models::Campaign::Reward::type_,
|
|
99
|
+
commission_structure: GrowsurfRuby::CommissionStructure?,
|
|
100
|
+
conversions_required: Integer?,
|
|
101
|
+
coupon_code: String?,
|
|
102
|
+
description: String?,
|
|
103
|
+
image_url: String?,
|
|
104
|
+
limit: Integer?,
|
|
105
|
+
limit_duration: GrowsurfRuby::Models::Campaign::Reward::limit_duration?,
|
|
106
|
+
next_milestone_prefix: String?,
|
|
107
|
+
next_milestone_suffix: String?,
|
|
108
|
+
number_of_winners: Integer?,
|
|
109
|
+
order: Integer?,
|
|
110
|
+
referral_coupon_code: String?,
|
|
111
|
+
referral_description: String?,
|
|
112
|
+
referred_reward_upfront: bool,
|
|
113
|
+
referred_value: GrowsurfRuby::RewardTaxValuation?,
|
|
114
|
+
value: GrowsurfRuby::RewardTaxValuation?
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
type type_ =
|
|
118
|
+
:SINGLE_SIDED | :DOUBLE_SIDED | :MILESTONE | :LEADERBOARD | :AFFILIATE
|
|
119
|
+
|
|
120
|
+
module Type
|
|
121
|
+
extend GrowsurfRuby::Internal::Type::Enum
|
|
122
|
+
|
|
123
|
+
SINGLE_SIDED: :SINGLE_SIDED
|
|
124
|
+
DOUBLE_SIDED: :DOUBLE_SIDED
|
|
125
|
+
MILESTONE: :MILESTONE
|
|
126
|
+
LEADERBOARD: :LEADERBOARD
|
|
127
|
+
AFFILIATE: :AFFILIATE
|
|
128
|
+
|
|
129
|
+
def self?.values: -> ::Array[GrowsurfRuby::Models::Campaign::Reward::type_]
|
|
130
|
+
end
|
|
131
|
+
|
|
132
|
+
type limit_duration = :IN_TOTAL | :PER_MONTH | :PER_YEAR
|
|
133
|
+
|
|
134
|
+
module LimitDuration
|
|
135
|
+
extend GrowsurfRuby::Internal::Type::Enum
|
|
136
|
+
|
|
137
|
+
IN_TOTAL: :IN_TOTAL
|
|
138
|
+
PER_MONTH: :PER_MONTH
|
|
139
|
+
PER_YEAR: :PER_YEAR
|
|
140
|
+
|
|
141
|
+
def self?.values: -> ::Array[GrowsurfRuby::Models::Campaign::Reward::limit_duration]
|
|
142
|
+
end
|
|
143
|
+
end
|
|
144
|
+
end
|
|
145
|
+
end
|
|
146
|
+
end
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
module GrowsurfRuby
|
|
2
|
+
module Models
|
|
3
|
+
module Campaign
|
|
4
|
+
type reward_create_params =
|
|
5
|
+
{
|
|
6
|
+
type: GrowsurfRuby::Models::Campaign::RewardCreateParams::type_,
|
|
7
|
+
commission_structure: GrowsurfRuby::CommissionStructure,
|
|
8
|
+
conversions_required: Integer,
|
|
9
|
+
coupon_code: String,
|
|
10
|
+
description: String,
|
|
11
|
+
image_url: String,
|
|
12
|
+
is_active: bool,
|
|
13
|
+
is_unlimited: bool,
|
|
14
|
+
is_visible: bool,
|
|
15
|
+
limit: Integer,
|
|
16
|
+
limit_duration: GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration,
|
|
17
|
+
metadata: ::Hash[Symbol, top],
|
|
18
|
+
next_milestone_prefix: String,
|
|
19
|
+
next_milestone_suffix: String,
|
|
20
|
+
number_of_winners: Integer,
|
|
21
|
+
order: Integer,
|
|
22
|
+
referral_coupon_code: String,
|
|
23
|
+
referral_description: String,
|
|
24
|
+
referred_reward_upfront: bool,
|
|
25
|
+
referred_value: GrowsurfRuby::RewardTaxValuation,
|
|
26
|
+
title: String,
|
|
27
|
+
value: GrowsurfRuby::RewardTaxValuation
|
|
28
|
+
}
|
|
29
|
+
& GrowsurfRuby::Internal::Type::request_parameters
|
|
30
|
+
|
|
31
|
+
class RewardCreateParams < GrowsurfRuby::Internal::Type::BaseModel
|
|
32
|
+
extend GrowsurfRuby::Internal::Type::RequestParameters::Converter
|
|
33
|
+
include GrowsurfRuby::Internal::Type::RequestParameters
|
|
34
|
+
|
|
35
|
+
attr_accessor type: GrowsurfRuby::Models::Campaign::RewardCreateParams::type_
|
|
36
|
+
|
|
37
|
+
attr_reader commission_structure: GrowsurfRuby::CommissionStructure?
|
|
38
|
+
|
|
39
|
+
def commission_structure=: (
|
|
40
|
+
GrowsurfRuby::CommissionStructure
|
|
41
|
+
) -> GrowsurfRuby::CommissionStructure
|
|
42
|
+
|
|
43
|
+
attr_reader conversions_required: Integer?
|
|
44
|
+
|
|
45
|
+
def conversions_required=: (Integer) -> Integer
|
|
46
|
+
|
|
47
|
+
attr_reader coupon_code: String?
|
|
48
|
+
|
|
49
|
+
def coupon_code=: (String) -> String
|
|
50
|
+
|
|
51
|
+
attr_reader description: String?
|
|
52
|
+
|
|
53
|
+
def description=: (String) -> String
|
|
54
|
+
|
|
55
|
+
attr_reader image_url: String?
|
|
56
|
+
|
|
57
|
+
def image_url=: (String) -> String
|
|
58
|
+
|
|
59
|
+
attr_reader is_active: bool?
|
|
60
|
+
|
|
61
|
+
def is_active=: (bool) -> bool
|
|
62
|
+
|
|
63
|
+
attr_reader is_unlimited: bool?
|
|
64
|
+
|
|
65
|
+
def is_unlimited=: (bool) -> bool
|
|
66
|
+
|
|
67
|
+
attr_reader is_visible: bool?
|
|
68
|
+
|
|
69
|
+
def is_visible=: (bool) -> bool
|
|
70
|
+
|
|
71
|
+
attr_reader limit: Integer?
|
|
72
|
+
|
|
73
|
+
def limit=: (Integer) -> Integer
|
|
74
|
+
|
|
75
|
+
attr_reader limit_duration: GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration?
|
|
76
|
+
|
|
77
|
+
def limit_duration=: (
|
|
78
|
+
GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration
|
|
79
|
+
) -> GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration
|
|
80
|
+
|
|
81
|
+
attr_reader metadata: ::Hash[Symbol, top]?
|
|
82
|
+
|
|
83
|
+
def metadata=: (::Hash[Symbol, top]) -> ::Hash[Symbol, top]
|
|
84
|
+
|
|
85
|
+
attr_reader next_milestone_prefix: String?
|
|
86
|
+
|
|
87
|
+
def next_milestone_prefix=: (String) -> String
|
|
88
|
+
|
|
89
|
+
attr_reader next_milestone_suffix: String?
|
|
90
|
+
|
|
91
|
+
def next_milestone_suffix=: (String) -> String
|
|
92
|
+
|
|
93
|
+
attr_reader number_of_winners: Integer?
|
|
94
|
+
|
|
95
|
+
def number_of_winners=: (Integer) -> Integer
|
|
96
|
+
|
|
97
|
+
attr_reader order: Integer?
|
|
98
|
+
|
|
99
|
+
def order=: (Integer) -> Integer
|
|
100
|
+
|
|
101
|
+
attr_reader referral_coupon_code: String?
|
|
102
|
+
|
|
103
|
+
def referral_coupon_code=: (String) -> String
|
|
104
|
+
|
|
105
|
+
attr_reader referral_description: String?
|
|
106
|
+
|
|
107
|
+
def referral_description=: (String) -> String
|
|
108
|
+
|
|
109
|
+
attr_reader referred_reward_upfront: bool?
|
|
110
|
+
|
|
111
|
+
def referred_reward_upfront=: (bool) -> bool
|
|
112
|
+
|
|
113
|
+
attr_reader referred_value: GrowsurfRuby::RewardTaxValuation?
|
|
114
|
+
|
|
115
|
+
def referred_value=: (
|
|
116
|
+
GrowsurfRuby::RewardTaxValuation
|
|
117
|
+
) -> GrowsurfRuby::RewardTaxValuation
|
|
118
|
+
|
|
119
|
+
attr_reader title: String?
|
|
120
|
+
|
|
121
|
+
def title=: (String) -> String
|
|
122
|
+
|
|
123
|
+
attr_reader value: GrowsurfRuby::RewardTaxValuation?
|
|
124
|
+
|
|
125
|
+
def value=: (
|
|
126
|
+
GrowsurfRuby::RewardTaxValuation
|
|
127
|
+
) -> GrowsurfRuby::RewardTaxValuation
|
|
128
|
+
|
|
129
|
+
def initialize: (
|
|
130
|
+
type: GrowsurfRuby::Models::Campaign::RewardCreateParams::type_,
|
|
131
|
+
?commission_structure: GrowsurfRuby::CommissionStructure,
|
|
132
|
+
?conversions_required: Integer,
|
|
133
|
+
?coupon_code: String,
|
|
134
|
+
?description: String,
|
|
135
|
+
?image_url: String,
|
|
136
|
+
?is_active: bool,
|
|
137
|
+
?is_unlimited: bool,
|
|
138
|
+
?is_visible: bool,
|
|
139
|
+
?limit: Integer,
|
|
140
|
+
?limit_duration: GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration,
|
|
141
|
+
?metadata: ::Hash[Symbol, top],
|
|
142
|
+
?next_milestone_prefix: String,
|
|
143
|
+
?next_milestone_suffix: String,
|
|
144
|
+
?number_of_winners: Integer,
|
|
145
|
+
?order: Integer,
|
|
146
|
+
?referral_coupon_code: String,
|
|
147
|
+
?referral_description: String,
|
|
148
|
+
?referred_reward_upfront: bool,
|
|
149
|
+
?referred_value: GrowsurfRuby::RewardTaxValuation,
|
|
150
|
+
?title: String,
|
|
151
|
+
?value: GrowsurfRuby::RewardTaxValuation,
|
|
152
|
+
?request_options: GrowsurfRuby::request_opts
|
|
153
|
+
) -> void
|
|
154
|
+
|
|
155
|
+
def to_hash: -> {
|
|
156
|
+
type: GrowsurfRuby::Models::Campaign::RewardCreateParams::type_,
|
|
157
|
+
commission_structure: GrowsurfRuby::CommissionStructure,
|
|
158
|
+
conversions_required: Integer,
|
|
159
|
+
coupon_code: String,
|
|
160
|
+
description: String,
|
|
161
|
+
image_url: String,
|
|
162
|
+
is_active: bool,
|
|
163
|
+
is_unlimited: bool,
|
|
164
|
+
is_visible: bool,
|
|
165
|
+
limit: Integer,
|
|
166
|
+
limit_duration: GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration,
|
|
167
|
+
metadata: ::Hash[Symbol, top],
|
|
168
|
+
next_milestone_prefix: String,
|
|
169
|
+
next_milestone_suffix: String,
|
|
170
|
+
number_of_winners: Integer,
|
|
171
|
+
order: Integer,
|
|
172
|
+
referral_coupon_code: String,
|
|
173
|
+
referral_description: String,
|
|
174
|
+
referred_reward_upfront: bool,
|
|
175
|
+
referred_value: GrowsurfRuby::RewardTaxValuation,
|
|
176
|
+
title: String,
|
|
177
|
+
value: GrowsurfRuby::RewardTaxValuation,
|
|
178
|
+
request_options: GrowsurfRuby::RequestOptions
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
type type_ =
|
|
182
|
+
:SINGLE_SIDED | :DOUBLE_SIDED | :MILESTONE | :LEADERBOARD | :AFFILIATE
|
|
183
|
+
|
|
184
|
+
module Type
|
|
185
|
+
extend GrowsurfRuby::Internal::Type::Enum
|
|
186
|
+
|
|
187
|
+
SINGLE_SIDED: :SINGLE_SIDED
|
|
188
|
+
DOUBLE_SIDED: :DOUBLE_SIDED
|
|
189
|
+
MILESTONE: :MILESTONE
|
|
190
|
+
LEADERBOARD: :LEADERBOARD
|
|
191
|
+
AFFILIATE: :AFFILIATE
|
|
192
|
+
|
|
193
|
+
def self?.values: -> ::Array[GrowsurfRuby::Models::Campaign::RewardCreateParams::type_]
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
type limit_duration = :IN_TOTAL | :PER_MONTH | :PER_YEAR
|
|
197
|
+
|
|
198
|
+
module LimitDuration
|
|
199
|
+
extend GrowsurfRuby::Internal::Type::Enum
|
|
200
|
+
|
|
201
|
+
IN_TOTAL: :IN_TOTAL
|
|
202
|
+
PER_MONTH: :PER_MONTH
|
|
203
|
+
PER_YEAR: :PER_YEAR
|
|
204
|
+
|
|
205
|
+
def self?.values: -> ::Array[GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration]
|
|
206
|
+
end
|
|
207
|
+
end
|
|
208
|
+
end
|
|
209
|
+
end
|
|
210
|
+
end
|
|
@@ -2,7 +2,7 @@ module GrowsurfRuby
|
|
|
2
2
|
module Models
|
|
3
3
|
module Campaign
|
|
4
4
|
type reward_delete_params =
|
|
5
|
-
{ id: String,
|
|
5
|
+
{ id: String, campaign_reward_id: String }
|
|
6
6
|
& GrowsurfRuby::Internal::Type::request_parameters
|
|
7
7
|
|
|
8
8
|
class RewardDeleteParams < GrowsurfRuby::Internal::Type::BaseModel
|
|
@@ -11,17 +11,17 @@ module GrowsurfRuby
|
|
|
11
11
|
|
|
12
12
|
attr_accessor id: String
|
|
13
13
|
|
|
14
|
-
attr_accessor
|
|
14
|
+
attr_accessor campaign_reward_id: String
|
|
15
15
|
|
|
16
16
|
def initialize: (
|
|
17
17
|
id: String,
|
|
18
|
-
|
|
18
|
+
campaign_reward_id: String,
|
|
19
19
|
?request_options: GrowsurfRuby::request_opts
|
|
20
20
|
) -> void
|
|
21
21
|
|
|
22
22
|
def to_hash: -> {
|
|
23
23
|
id: String,
|
|
24
|
-
|
|
24
|
+
campaign_reward_id: String,
|
|
25
25
|
request_options: GrowsurfRuby::RequestOptions
|
|
26
26
|
}
|
|
27
27
|
end
|
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
module GrowsurfRuby
|
|
2
|
+
module Models
|
|
3
|
+
module Campaign
|
|
4
|
+
type reward_update_params =
|
|
5
|
+
{
|
|
6
|
+
id: String,
|
|
7
|
+
campaign_reward_id: String,
|
|
8
|
+
commission_structure: GrowsurfRuby::CommissionStructure,
|
|
9
|
+
conversions_required: Integer,
|
|
10
|
+
coupon_code: String,
|
|
11
|
+
description: String,
|
|
12
|
+
image_url: String,
|
|
13
|
+
is_active: bool,
|
|
14
|
+
is_unlimited: bool,
|
|
15
|
+
is_visible: bool,
|
|
16
|
+
limit: Integer,
|
|
17
|
+
limit_duration: GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration,
|
|
18
|
+
metadata: ::Hash[Symbol, top],
|
|
19
|
+
next_milestone_prefix: String,
|
|
20
|
+
next_milestone_suffix: String,
|
|
21
|
+
number_of_winners: Integer,
|
|
22
|
+
order: Integer,
|
|
23
|
+
referral_coupon_code: String,
|
|
24
|
+
referral_description: String,
|
|
25
|
+
referred_reward_upfront: bool,
|
|
26
|
+
referred_value: GrowsurfRuby::RewardTaxValuation,
|
|
27
|
+
title: String,
|
|
28
|
+
value: GrowsurfRuby::RewardTaxValuation
|
|
29
|
+
}
|
|
30
|
+
& GrowsurfRuby::Internal::Type::request_parameters
|
|
31
|
+
|
|
32
|
+
class RewardUpdateParams < GrowsurfRuby::Internal::Type::BaseModel
|
|
33
|
+
extend GrowsurfRuby::Internal::Type::RequestParameters::Converter
|
|
34
|
+
include GrowsurfRuby::Internal::Type::RequestParameters
|
|
35
|
+
|
|
36
|
+
attr_accessor id: String
|
|
37
|
+
|
|
38
|
+
attr_accessor campaign_reward_id: String
|
|
39
|
+
|
|
40
|
+
attr_reader commission_structure: GrowsurfRuby::CommissionStructure?
|
|
41
|
+
|
|
42
|
+
def commission_structure=: (
|
|
43
|
+
GrowsurfRuby::CommissionStructure
|
|
44
|
+
) -> GrowsurfRuby::CommissionStructure
|
|
45
|
+
|
|
46
|
+
attr_reader conversions_required: Integer?
|
|
47
|
+
|
|
48
|
+
def conversions_required=: (Integer) -> Integer
|
|
49
|
+
|
|
50
|
+
attr_reader coupon_code: String?
|
|
51
|
+
|
|
52
|
+
def coupon_code=: (String) -> String
|
|
53
|
+
|
|
54
|
+
attr_reader description: String?
|
|
55
|
+
|
|
56
|
+
def description=: (String) -> String
|
|
57
|
+
|
|
58
|
+
attr_reader image_url: String?
|
|
59
|
+
|
|
60
|
+
def image_url=: (String) -> String
|
|
61
|
+
|
|
62
|
+
attr_reader is_active: bool?
|
|
63
|
+
|
|
64
|
+
def is_active=: (bool) -> bool
|
|
65
|
+
|
|
66
|
+
attr_reader is_unlimited: bool?
|
|
67
|
+
|
|
68
|
+
def is_unlimited=: (bool) -> bool
|
|
69
|
+
|
|
70
|
+
attr_reader is_visible: bool?
|
|
71
|
+
|
|
72
|
+
def is_visible=: (bool) -> bool
|
|
73
|
+
|
|
74
|
+
attr_reader limit: Integer?
|
|
75
|
+
|
|
76
|
+
def limit=: (Integer) -> Integer
|
|
77
|
+
|
|
78
|
+
attr_reader limit_duration: GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration?
|
|
79
|
+
|
|
80
|
+
def limit_duration=: (
|
|
81
|
+
GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration
|
|
82
|
+
) -> GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration
|
|
83
|
+
|
|
84
|
+
attr_reader metadata: ::Hash[Symbol, top]?
|
|
85
|
+
|
|
86
|
+
def metadata=: (::Hash[Symbol, top]) -> ::Hash[Symbol, top]
|
|
87
|
+
|
|
88
|
+
attr_reader next_milestone_prefix: String?
|
|
89
|
+
|
|
90
|
+
def next_milestone_prefix=: (String) -> String
|
|
91
|
+
|
|
92
|
+
attr_reader next_milestone_suffix: String?
|
|
93
|
+
|
|
94
|
+
def next_milestone_suffix=: (String) -> String
|
|
95
|
+
|
|
96
|
+
attr_reader number_of_winners: Integer?
|
|
97
|
+
|
|
98
|
+
def number_of_winners=: (Integer) -> Integer
|
|
99
|
+
|
|
100
|
+
attr_reader order: Integer?
|
|
101
|
+
|
|
102
|
+
def order=: (Integer) -> Integer
|
|
103
|
+
|
|
104
|
+
attr_reader referral_coupon_code: String?
|
|
105
|
+
|
|
106
|
+
def referral_coupon_code=: (String) -> String
|
|
107
|
+
|
|
108
|
+
attr_reader referral_description: String?
|
|
109
|
+
|
|
110
|
+
def referral_description=: (String) -> String
|
|
111
|
+
|
|
112
|
+
attr_reader referred_reward_upfront: bool?
|
|
113
|
+
|
|
114
|
+
def referred_reward_upfront=: (bool) -> bool
|
|
115
|
+
|
|
116
|
+
attr_reader referred_value: GrowsurfRuby::RewardTaxValuation?
|
|
117
|
+
|
|
118
|
+
def referred_value=: (
|
|
119
|
+
GrowsurfRuby::RewardTaxValuation
|
|
120
|
+
) -> GrowsurfRuby::RewardTaxValuation
|
|
121
|
+
|
|
122
|
+
attr_reader title: String?
|
|
123
|
+
|
|
124
|
+
def title=: (String) -> String
|
|
125
|
+
|
|
126
|
+
attr_reader value: GrowsurfRuby::RewardTaxValuation?
|
|
127
|
+
|
|
128
|
+
def value=: (
|
|
129
|
+
GrowsurfRuby::RewardTaxValuation
|
|
130
|
+
) -> GrowsurfRuby::RewardTaxValuation
|
|
131
|
+
|
|
132
|
+
def initialize: (
|
|
133
|
+
id: String,
|
|
134
|
+
campaign_reward_id: String,
|
|
135
|
+
?commission_structure: GrowsurfRuby::CommissionStructure,
|
|
136
|
+
?conversions_required: Integer,
|
|
137
|
+
?coupon_code: String,
|
|
138
|
+
?description: String,
|
|
139
|
+
?image_url: String,
|
|
140
|
+
?is_active: bool,
|
|
141
|
+
?is_unlimited: bool,
|
|
142
|
+
?is_visible: bool,
|
|
143
|
+
?limit: Integer,
|
|
144
|
+
?limit_duration: GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration,
|
|
145
|
+
?metadata: ::Hash[Symbol, top],
|
|
146
|
+
?next_milestone_prefix: String,
|
|
147
|
+
?next_milestone_suffix: String,
|
|
148
|
+
?number_of_winners: Integer,
|
|
149
|
+
?order: Integer,
|
|
150
|
+
?referral_coupon_code: String,
|
|
151
|
+
?referral_description: String,
|
|
152
|
+
?referred_reward_upfront: bool,
|
|
153
|
+
?referred_value: GrowsurfRuby::RewardTaxValuation,
|
|
154
|
+
?title: String,
|
|
155
|
+
?value: GrowsurfRuby::RewardTaxValuation,
|
|
156
|
+
?request_options: GrowsurfRuby::request_opts
|
|
157
|
+
) -> void
|
|
158
|
+
|
|
159
|
+
def to_hash: -> {
|
|
160
|
+
id: String,
|
|
161
|
+
campaign_reward_id: String,
|
|
162
|
+
commission_structure: GrowsurfRuby::CommissionStructure,
|
|
163
|
+
conversions_required: Integer,
|
|
164
|
+
coupon_code: String,
|
|
165
|
+
description: String,
|
|
166
|
+
image_url: String,
|
|
167
|
+
is_active: bool,
|
|
168
|
+
is_unlimited: bool,
|
|
169
|
+
is_visible: bool,
|
|
170
|
+
limit: Integer,
|
|
171
|
+
limit_duration: GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration,
|
|
172
|
+
metadata: ::Hash[Symbol, top],
|
|
173
|
+
next_milestone_prefix: String,
|
|
174
|
+
next_milestone_suffix: String,
|
|
175
|
+
number_of_winners: Integer,
|
|
176
|
+
order: Integer,
|
|
177
|
+
referral_coupon_code: String,
|
|
178
|
+
referral_description: String,
|
|
179
|
+
referred_reward_upfront: bool,
|
|
180
|
+
referred_value: GrowsurfRuby::RewardTaxValuation,
|
|
181
|
+
title: String,
|
|
182
|
+
value: GrowsurfRuby::RewardTaxValuation,
|
|
183
|
+
request_options: GrowsurfRuby::RequestOptions
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
type limit_duration = :IN_TOTAL | :PER_MONTH | :PER_YEAR
|
|
187
|
+
|
|
188
|
+
module LimitDuration
|
|
189
|
+
extend GrowsurfRuby::Internal::Type::Enum
|
|
190
|
+
|
|
191
|
+
IN_TOTAL: :IN_TOTAL
|
|
192
|
+
PER_MONTH: :PER_MONTH
|
|
193
|
+
PER_YEAR: :PER_YEAR
|
|
194
|
+
|
|
195
|
+
def self?.values: -> ::Array[GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration]
|
|
196
|
+
end
|
|
197
|
+
end
|
|
198
|
+
end
|
|
199
|
+
end
|
|
200
|
+
end
|
|
@@ -85,8 +85,11 @@ module GrowsurfRuby
|
|
|
85
85
|
next_milestone_suffix: String?,
|
|
86
86
|
number_of_winners: Integer?,
|
|
87
87
|
order: Integer?,
|
|
88
|
+
referral_coupon_code: String?,
|
|
88
89
|
referral_description: String?,
|
|
89
|
-
referred_reward_upfront: bool
|
|
90
|
+
referred_reward_upfront: bool,
|
|
91
|
+
referred_value: GrowsurfRuby::RewardTaxValuation?,
|
|
92
|
+
value: GrowsurfRuby::RewardTaxValuation?
|
|
90
93
|
}
|
|
91
94
|
|
|
92
95
|
class Reward < GrowsurfRuby::Internal::Type::BaseModel
|
|
@@ -120,12 +123,18 @@ module GrowsurfRuby
|
|
|
120
123
|
|
|
121
124
|
attr_accessor order: Integer?
|
|
122
125
|
|
|
126
|
+
attr_accessor referral_coupon_code: String?
|
|
127
|
+
|
|
123
128
|
attr_accessor referral_description: String?
|
|
124
129
|
|
|
125
130
|
attr_reader referred_reward_upfront: bool?
|
|
126
131
|
|
|
127
132
|
def referred_reward_upfront=: (bool) -> bool
|
|
128
133
|
|
|
134
|
+
attr_accessor referred_value: GrowsurfRuby::RewardTaxValuation?
|
|
135
|
+
|
|
136
|
+
attr_accessor value: GrowsurfRuby::RewardTaxValuation?
|
|
137
|
+
|
|
129
138
|
def initialize: (
|
|
130
139
|
id: String,
|
|
131
140
|
is_unlimited: bool,
|
|
@@ -142,8 +151,11 @@ module GrowsurfRuby
|
|
|
142
151
|
?next_milestone_suffix: String?,
|
|
143
152
|
?number_of_winners: Integer?,
|
|
144
153
|
?order: Integer?,
|
|
154
|
+
?referral_coupon_code: String?,
|
|
145
155
|
?referral_description: String?,
|
|
146
|
-
?referred_reward_upfront: bool
|
|
156
|
+
?referred_reward_upfront: bool,
|
|
157
|
+
?referred_value: GrowsurfRuby::RewardTaxValuation?,
|
|
158
|
+
?value: GrowsurfRuby::RewardTaxValuation?
|
|
147
159
|
) -> void
|
|
148
160
|
|
|
149
161
|
def to_hash: -> {
|
|
@@ -162,8 +174,11 @@ module GrowsurfRuby
|
|
|
162
174
|
next_milestone_suffix: String?,
|
|
163
175
|
number_of_winners: Integer?,
|
|
164
176
|
order: Integer?,
|
|
177
|
+
referral_coupon_code: String?,
|
|
165
178
|
referral_description: String?,
|
|
166
|
-
referred_reward_upfront: bool
|
|
179
|
+
referred_reward_upfront: bool,
|
|
180
|
+
referred_value: GrowsurfRuby::RewardTaxValuation?,
|
|
181
|
+
value: GrowsurfRuby::RewardTaxValuation?
|
|
167
182
|
}
|
|
168
183
|
|
|
169
184
|
type type_ =
|