growsurf-ruby 1.3.0 → 1.5.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.
Files changed (142) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +29 -0
  3. data/README.md +10 -7
  4. data/lib/growsurf_ruby/internal/transport/base_client.rb +6 -1
  5. data/lib/growsurf_ruby/internal/type/base_model.rb +26 -0
  6. data/lib/growsurf_ruby/internal/type/base_page.rb +6 -0
  7. data/lib/growsurf_ruby/models/account_create_response.rb +3 -3
  8. data/lib/growsurf_ruby/models/analytics_availability.rb +16 -0
  9. data/lib/growsurf_ruby/models/analytics_unavailable_reason.rb +20 -0
  10. data/lib/growsurf_ruby/models/campaign/delete_program_resource_response.rb +12 -0
  11. data/lib/growsurf_ruby/models/campaign/integration.rb +69 -0
  12. data/lib/growsurf_ruby/models/campaign/integration_list_response.rb +24 -0
  13. data/lib/growsurf_ruby/models/campaign/participant_activation_analytics.rb +75 -0
  14. data/lib/growsurf_ruby/models/campaign/participant_analytics_response.rb +11 -0
  15. data/lib/growsurf_ruby/models/campaign/participant_get_payout_destination_response.rb +17 -17
  16. data/lib/growsurf_ruby/models/campaign/participant_record_transaction_params.rb +9 -1
  17. data/lib/growsurf_ruby/models/campaign/participant_refund_transaction_params.rb +17 -1
  18. data/lib/growsurf_ruby/models/campaign/participant_request_payout_destination_confirmation_response.rb +8 -8
  19. data/lib/growsurf_ruby/models/campaign/participant_retrieve_analytics_params.rb +15 -11
  20. data/lib/growsurf_ruby/models/campaign/participant_reward.rb +16 -3
  21. data/lib/growsurf_ruby/models/campaign/program_resource.rb +51 -0
  22. data/lib/growsurf_ruby/models/campaign/program_resource_create_params.rb +32 -0
  23. data/lib/growsurf_ruby/models/campaign/program_resource_delete_params.rb +14 -0
  24. data/lib/growsurf_ruby/models/campaign/program_resource_list_response.rb +12 -0
  25. data/lib/growsurf_ruby/models/campaign/program_resource_update_params.rb +35 -0
  26. data/lib/growsurf_ruby/models/campaign/program_resource_upload_result.rb +33 -0
  27. data/lib/growsurf_ruby/models/campaign/program_resource_upload_ticket.rb +26 -0
  28. data/lib/growsurf_ruby/models/campaign/program_resource_upload_ticket_params.rb +17 -0
  29. data/lib/growsurf_ruby/models/campaign/reward.rb +22 -1
  30. data/lib/growsurf_ruby/models/campaign/reward_create_params.rb +32 -9
  31. data/lib/growsurf_ruby/models/campaign/reward_update_params.rb +32 -9
  32. data/lib/growsurf_ruby/models/campaign.rb +25 -2
  33. data/lib/growsurf_ruby/models/campaign_activation_analytics_response.rb +186 -0
  34. data/lib/growsurf_ruby/models/campaign_create_params.rb +37 -1
  35. data/lib/growsurf_ruby/models/campaign_engagement_analytics.rb +174 -0
  36. data/lib/growsurf_ruby/models/campaign_retrieve_activation_analytics_params.rb +35 -0
  37. data/lib/growsurf_ruby/models/campaign_retrieve_analytics_params.rb +37 -4
  38. data/lib/growsurf_ruby/models/campaign_retrieve_analytics_response.rb +3 -0
  39. data/lib/growsurf_ruby/models/commission_structure.rb +19 -3
  40. data/lib/growsurf_ruby/models/participant_commission_list.rb +24 -6
  41. data/lib/growsurf_ruby/models/participant_payout_list.rb +5 -5
  42. data/lib/growsurf_ruby/models.rb +7 -0
  43. data/lib/growsurf_ruby/resources/account.rb +17 -11
  44. data/lib/growsurf_ruby/resources/campaign/design.rb +11 -5
  45. data/lib/growsurf_ruby/resources/campaign/emails.rb +2 -1
  46. data/lib/growsurf_ruby/resources/campaign/integrations.rb +41 -0
  47. data/lib/growsurf_ruby/resources/campaign/participant.rb +28 -25
  48. data/lib/growsurf_ruby/resources/campaign/program_resources.rb +112 -0
  49. data/lib/growsurf_ruby/resources/campaign/rewards.rb +12 -6
  50. data/lib/growsurf_ruby/resources/campaign.rb +53 -7
  51. data/lib/growsurf_ruby/resources/team.rb +7 -5
  52. data/lib/growsurf_ruby/version.rb +1 -1
  53. data/lib/growsurf_ruby.rb +19 -0
  54. data/rbi/growsurf_ruby/internal/type/base_model.rbi +10 -0
  55. data/rbi/growsurf_ruby/internal/type/base_page.rbi +3 -0
  56. data/rbi/growsurf_ruby/models/analytics_availability.rbi +19 -0
  57. data/rbi/growsurf_ruby/models/analytics_unavailable_reason.rbi +23 -0
  58. data/rbi/growsurf_ruby/models/campaign/delete_program_resource_response.rbi +33 -0
  59. data/rbi/growsurf_ruby/models/campaign/integration.rbi +93 -0
  60. data/rbi/growsurf_ruby/models/campaign/integration_list_response.rbi +46 -0
  61. data/rbi/growsurf_ruby/models/campaign/participant_activation_analytics.rbi +133 -0
  62. data/rbi/growsurf_ruby/models/campaign/participant_analytics_response.rbi +35 -0
  63. data/rbi/growsurf_ruby/models/campaign/participant_get_payout_destination_response.rbi +17 -23
  64. data/rbi/growsurf_ruby/models/campaign/participant_record_transaction_params.rbi +18 -0
  65. data/rbi/growsurf_ruby/models/campaign/participant_refund_transaction_params.rbi +18 -0
  66. data/rbi/growsurf_ruby/models/campaign/participant_request_payout_destination_confirmation_response.rbi +7 -9
  67. data/rbi/growsurf_ruby/models/campaign/participant_retrieve_analytics_params.rbi +16 -10
  68. data/rbi/growsurf_ruby/models/campaign/participant_reward.rbi +29 -6
  69. data/rbi/growsurf_ruby/models/campaign/program_resource.rbi +186 -0
  70. data/rbi/growsurf_ruby/models/campaign/program_resource_create_params.rbi +95 -0
  71. data/rbi/growsurf_ruby/models/campaign/program_resource_delete_params.rbi +37 -0
  72. data/rbi/growsurf_ruby/models/campaign/program_resource_list_response.rbi +29 -0
  73. data/rbi/growsurf_ruby/models/campaign/program_resource_update_params.rbi +105 -0
  74. data/rbi/growsurf_ruby/models/campaign/program_resource_upload_result.rbi +94 -0
  75. data/rbi/growsurf_ruby/models/campaign/program_resource_upload_ticket.rbi +57 -0
  76. data/rbi/growsurf_ruby/models/campaign/program_resource_upload_ticket_params.rbi +53 -0
  77. data/rbi/growsurf_ruby/models/campaign/reward.rbi +55 -0
  78. data/rbi/growsurf_ruby/models/campaign/reward_create_params.rbi +97 -24
  79. data/rbi/growsurf_ruby/models/campaign/reward_update_params.rbi +97 -24
  80. data/rbi/growsurf_ruby/models/campaign.rbi +52 -3
  81. data/rbi/growsurf_ruby/models/campaign_activation_analytics_response.rbi +325 -0
  82. data/rbi/growsurf_ruby/models/campaign_create_params.rbi +91 -0
  83. data/rbi/growsurf_ruby/models/campaign_engagement_analytics.rbi +369 -0
  84. data/rbi/growsurf_ruby/models/campaign_retrieve_activation_analytics_params.rbi +59 -0
  85. data/rbi/growsurf_ruby/models/campaign_retrieve_analytics_params.rbi +56 -3
  86. data/rbi/growsurf_ruby/models/campaign_retrieve_analytics_response.rbi +27 -7
  87. data/rbi/growsurf_ruby/models/commission_structure.rbi +36 -3
  88. data/rbi/growsurf_ruby/models/participant_commission_list.rbi +63 -15
  89. data/rbi/growsurf_ruby/models/participant_payout_list.rbi +15 -15
  90. data/rbi/growsurf_ruby/models.rbi +7 -0
  91. data/rbi/growsurf_ruby/resources/account.rbi +9 -6
  92. data/rbi/growsurf_ruby/resources/campaign/design.rbi +32 -4
  93. data/rbi/growsurf_ruby/resources/campaign/emails.rbi +2 -1
  94. data/rbi/growsurf_ruby/resources/campaign/integrations.rbi +35 -0
  95. data/rbi/growsurf_ruby/resources/campaign/participant.rbi +38 -24
  96. data/rbi/growsurf_ruby/resources/campaign/program_resources.rbi +116 -0
  97. data/rbi/growsurf_ruby/resources/campaign/rewards.rbi +35 -16
  98. data/rbi/growsurf_ruby/resources/campaign.rbi +53 -5
  99. data/rbi/growsurf_ruby/resources/team.rbi +7 -5
  100. data/sig/growsurf_ruby/internal/type/base_model.rbs +6 -0
  101. data/sig/growsurf_ruby/internal/type/base_page.rbs +2 -0
  102. data/sig/growsurf_ruby/models/analytics_availability.rbs +15 -0
  103. data/sig/growsurf_ruby/models/analytics_unavailable_reason.rbs +26 -0
  104. data/sig/growsurf_ruby/models/campaign/delete_program_resource_response.rbs +14 -0
  105. data/sig/growsurf_ruby/models/campaign/integration.rbs +47 -0
  106. data/sig/growsurf_ruby/models/campaign/integration_list_response.rbs +20 -0
  107. data/sig/growsurf_ruby/models/campaign/participant_activation_analytics.rbs +96 -0
  108. data/sig/growsurf_ruby/models/campaign/participant_analytics_response.rbs +22 -1
  109. data/sig/growsurf_ruby/models/campaign/participant_get_payout_destination_response.rbs +17 -22
  110. data/sig/growsurf_ruby/models/campaign/participant_record_transaction_params.rbs +15 -1
  111. data/sig/growsurf_ruby/models/campaign/participant_refund_transaction_params.rbs +15 -1
  112. data/sig/growsurf_ruby/models/campaign/participant_request_payout_destination_confirmation_response.rbs +8 -10
  113. data/sig/growsurf_ruby/models/campaign/participant_reward.rbs +24 -9
  114. data/sig/growsurf_ruby/models/campaign/program_resource.rbs +94 -0
  115. data/sig/growsurf_ruby/models/campaign/program_resource_create_params.rbs +45 -0
  116. data/sig/growsurf_ruby/models/campaign/program_resource_delete_params.rbs +22 -0
  117. data/sig/growsurf_ruby/models/campaign/program_resource_list_response.rbs +14 -0
  118. data/sig/growsurf_ruby/models/campaign/program_resource_update_params.rbs +48 -0
  119. data/sig/growsurf_ruby/models/campaign/program_resource_upload_result.rbs +58 -0
  120. data/sig/growsurf_ruby/models/campaign/program_resource_upload_ticket.rbs +29 -0
  121. data/sig/growsurf_ruby/models/campaign/program_resource_upload_ticket_params.rbs +29 -0
  122. data/sig/growsurf_ruby/models/campaign/reward.rbs +16 -0
  123. data/sig/growsurf_ruby/models/campaign/reward_create_params.rbs +54 -34
  124. data/sig/growsurf_ruby/models/campaign/reward_update_params.rbs +54 -34
  125. data/sig/growsurf_ruby/models/campaign.rbs +23 -5
  126. data/sig/growsurf_ruby/models/campaign_activation_analytics_response.rbs +202 -0
  127. data/sig/growsurf_ruby/models/campaign_create_params.rbs +29 -0
  128. data/sig/growsurf_ruby/models/campaign_engagement_analytics.rbs +186 -0
  129. data/sig/growsurf_ruby/models/campaign_retrieve_activation_analytics_params.rbs +45 -0
  130. data/sig/growsurf_ruby/models/campaign_retrieve_analytics_params.rbs +30 -1
  131. data/sig/growsurf_ruby/models/campaign_retrieve_analytics_response.rbs +21 -3
  132. data/sig/growsurf_ruby/models/commission_structure.rbs +16 -4
  133. data/sig/growsurf_ruby/models/participant_commission_list.rbs +36 -20
  134. data/sig/growsurf_ruby/models/participant_payout_list.rbs +20 -20
  135. data/sig/growsurf_ruby/models.rbs +6 -0
  136. data/sig/growsurf_ruby/resources/campaign/design.rbs +19 -0
  137. data/sig/growsurf_ruby/resources/campaign/integrations.rbs +14 -0
  138. data/sig/growsurf_ruby/resources/campaign/participant.rbs +4 -0
  139. data/sig/growsurf_ruby/resources/campaign/program_resources.rbs +58 -0
  140. data/sig/growsurf_ruby/resources/campaign/rewards.rbs +14 -12
  141. data/sig/growsurf_ruby/resources/campaign.rbs +17 -0
  142. metadata +59 -2
@@ -7,7 +7,7 @@ module GrowsurfRuby
7
7
  approval_required: bool?,
8
8
  duration: String?,
9
9
  duration_in_months: Integer?,
10
- event: String?,
10
+ event: GrowsurfRuby::Models::CommissionStructure::event?,
11
11
  has_intro: bool?,
12
12
  has_max_amount: bool?,
13
13
  hold_duration: Integer?,
@@ -35,7 +35,7 @@ module GrowsurfRuby
35
35
 
36
36
  attr_accessor duration_in_months: Integer?
37
37
 
38
- attr_accessor event: String?
38
+ attr_accessor event: GrowsurfRuby::Models::CommissionStructure::event?
39
39
 
40
40
  attr_accessor has_intro: bool?
41
41
 
@@ -71,7 +71,7 @@ module GrowsurfRuby
71
71
  ?approval_required: bool?,
72
72
  ?duration: String?,
73
73
  ?duration_in_months: Integer?,
74
- ?event: String?,
74
+ ?event: GrowsurfRuby::Models::CommissionStructure::event?,
75
75
  ?has_intro: bool?,
76
76
  ?has_max_amount: bool?,
77
77
  ?hold_duration: Integer?,
@@ -94,7 +94,7 @@ module GrowsurfRuby
94
94
  approval_required: bool?,
95
95
  duration: String?,
96
96
  duration_in_months: Integer?,
97
- event: String?,
97
+ event: GrowsurfRuby::Models::CommissionStructure::event?,
98
98
  has_intro: bool?,
99
99
  has_max_amount: bool?,
100
100
  hold_duration: Integer?,
@@ -111,6 +111,18 @@ module GrowsurfRuby
111
111
  type: GrowsurfRuby::Models::CommissionStructure::type_?
112
112
  }
113
113
 
114
+ type event = :CLICK | :LEAD | :SALE
115
+
116
+ module Event
117
+ extend GrowsurfRuby::Internal::Type::Enum
118
+
119
+ CLICK: :CLICK
120
+ LEAD: :LEAD
121
+ SALE: :SALE
122
+
123
+ def self?.values: -> ::Array[GrowsurfRuby::Models::CommissionStructure::event]
124
+ end
125
+
114
126
  type type_ = :PERCENT | :FIXED
115
127
 
116
128
  module Type
@@ -32,21 +32,22 @@ module GrowsurfRuby
32
32
  amount: Integer?,
33
33
  created_at: Integer,
34
34
  currency_iso: String,
35
+ event: GrowsurfRuby::Models::ParticipantCommissionList::Commission::event,
35
36
  referred_id: String,
36
37
  referrer_id: String,
37
38
  sale_amount: Integer?,
38
39
  status: GrowsurfRuby::Models::ParticipantCommissionList::Commission::status,
39
40
  amount_in_campaign_currency: Integer?,
40
- approved_at: Integer,
41
+ approved_at: Integer?,
41
42
  campaign_currency_iso: String?,
42
43
  exchange_rate: Float?,
43
- exchange_rate_at: Integer,
44
+ exchange_rate_at: Integer?,
44
45
  fx_error: String?,
45
46
  hold_duration: Integer?,
46
- paid_at: Integer,
47
- payout_queued_at: Integer,
47
+ paid_at: Integer?,
48
+ payout_queued_at: Integer?,
48
49
  provider: String?,
49
- reversed_at: Integer,
50
+ reversed_at: Integer?,
50
51
  sale_amount_in_campaign_currency: Integer?
51
52
  }
52
53
 
@@ -59,6 +60,8 @@ module GrowsurfRuby
59
60
 
60
61
  attr_accessor currency_iso: String
61
62
 
63
+ attr_accessor event: GrowsurfRuby::Models::ParticipantCommissionList::Commission::event
64
+
62
65
  attr_accessor referred_id: String
63
66
 
64
67
  attr_accessor referrer_id: String
@@ -71,7 +74,7 @@ module GrowsurfRuby
71
74
 
72
75
  attr_reader approved_at: Integer?
73
76
 
74
- def approved_at=: (Integer) -> Integer
77
+ def approved_at=: (Integer?) -> Integer?
75
78
 
76
79
  attr_accessor campaign_currency_iso: String?
77
80
 
@@ -79,7 +82,7 @@ module GrowsurfRuby
79
82
 
80
83
  attr_reader exchange_rate_at: Integer?
81
84
 
82
- def exchange_rate_at=: (Integer) -> Integer
85
+ def exchange_rate_at=: (Integer?) -> Integer?
83
86
 
84
87
  attr_accessor fx_error: String?
85
88
 
@@ -87,17 +90,17 @@ module GrowsurfRuby
87
90
 
88
91
  attr_reader paid_at: Integer?
89
92
 
90
- def paid_at=: (Integer) -> Integer
93
+ def paid_at=: (Integer?) -> Integer?
91
94
 
92
95
  attr_reader payout_queued_at: Integer?
93
96
 
94
- def payout_queued_at=: (Integer) -> Integer
97
+ def payout_queued_at=: (Integer?) -> Integer?
95
98
 
96
99
  attr_accessor provider: String?
97
100
 
98
101
  attr_reader reversed_at: Integer?
99
102
 
100
- def reversed_at=: (Integer) -> Integer
103
+ def reversed_at=: (Integer?) -> Integer?
101
104
 
102
105
  attr_accessor sale_amount_in_campaign_currency: Integer?
103
106
 
@@ -106,21 +109,22 @@ module GrowsurfRuby
106
109
  amount: Integer?,
107
110
  created_at: Integer,
108
111
  currency_iso: String,
112
+ event: GrowsurfRuby::Models::ParticipantCommissionList::Commission::event,
109
113
  referred_id: String,
110
114
  referrer_id: String,
111
115
  sale_amount: Integer?,
112
116
  status: GrowsurfRuby::Models::ParticipantCommissionList::Commission::status,
113
117
  ?amount_in_campaign_currency: Integer?,
114
- ?approved_at: Integer,
118
+ ?approved_at: Integer?,
115
119
  ?campaign_currency_iso: String?,
116
120
  ?exchange_rate: Float?,
117
- ?exchange_rate_at: Integer,
121
+ ?exchange_rate_at: Integer?,
118
122
  ?fx_error: String?,
119
123
  ?hold_duration: Integer?,
120
- ?paid_at: Integer,
121
- ?payout_queued_at: Integer,
124
+ ?paid_at: Integer?,
125
+ ?payout_queued_at: Integer?,
122
126
  ?provider: String?,
123
- ?reversed_at: Integer,
127
+ ?reversed_at: Integer?,
124
128
  ?sale_amount_in_campaign_currency: Integer?
125
129
  ) -> void
126
130
 
@@ -129,24 +133,36 @@ module GrowsurfRuby
129
133
  amount: Integer?,
130
134
  created_at: Integer,
131
135
  currency_iso: String,
136
+ event: GrowsurfRuby::Models::ParticipantCommissionList::Commission::event,
132
137
  referred_id: String,
133
138
  referrer_id: String,
134
139
  sale_amount: Integer?,
135
140
  status: GrowsurfRuby::Models::ParticipantCommissionList::Commission::status,
136
141
  amount_in_campaign_currency: Integer?,
137
- approved_at: Integer,
142
+ approved_at: Integer?,
138
143
  campaign_currency_iso: String?,
139
144
  exchange_rate: Float?,
140
- exchange_rate_at: Integer,
145
+ exchange_rate_at: Integer?,
141
146
  fx_error: String?,
142
147
  hold_duration: Integer?,
143
- paid_at: Integer,
144
- payout_queued_at: Integer,
148
+ paid_at: Integer?,
149
+ payout_queued_at: Integer?,
145
150
  provider: String?,
146
- reversed_at: Integer,
151
+ reversed_at: Integer?,
147
152
  sale_amount_in_campaign_currency: Integer?
148
153
  }
149
154
 
155
+ type event = :LEAD | :SALE
156
+
157
+ module Event
158
+ extend GrowsurfRuby::Internal::Type::Enum
159
+
160
+ LEAD: :LEAD
161
+ SALE: :SALE
162
+
163
+ def self?.values: -> ::Array[GrowsurfRuby::Models::ParticipantCommissionList::Commission::event]
164
+ end
165
+
150
166
  type status = :PENDING | :APPROVED | :PAID | :REVERSED | :DELETED
151
167
 
152
168
  module Status
@@ -38,13 +38,13 @@ module GrowsurfRuby
38
38
  amount_in_campaign_currency: Integer?,
39
39
  campaign_currency_iso: String?,
40
40
  exchange_rate: Float?,
41
- exchange_rate_at: Integer,
42
- failed_at: Integer,
41
+ exchange_rate_at: Integer?,
42
+ failed_at: Integer?,
43
43
  fx_error: String?,
44
- issued_at: Integer,
44
+ issued_at: Integer?,
45
45
  provider: String?,
46
- queued_at: Integer,
47
- reversed_at: Integer
46
+ queued_at: Integer?,
47
+ reversed_at: Integer?
48
48
  }
49
49
 
50
50
  class Payout < GrowsurfRuby::Internal::Type::BaseModel
@@ -70,27 +70,27 @@ module GrowsurfRuby
70
70
 
71
71
  attr_reader exchange_rate_at: Integer?
72
72
 
73
- def exchange_rate_at=: (Integer) -> Integer
73
+ def exchange_rate_at=: (Integer?) -> Integer?
74
74
 
75
75
  attr_reader failed_at: Integer?
76
76
 
77
- def failed_at=: (Integer) -> Integer
77
+ def failed_at=: (Integer?) -> Integer?
78
78
 
79
79
  attr_accessor fx_error: String?
80
80
 
81
81
  attr_reader issued_at: Integer?
82
82
 
83
- def issued_at=: (Integer) -> Integer
83
+ def issued_at=: (Integer?) -> Integer?
84
84
 
85
85
  attr_accessor provider: String?
86
86
 
87
87
  attr_reader queued_at: Integer?
88
88
 
89
- def queued_at=: (Integer) -> Integer
89
+ def queued_at=: (Integer?) -> Integer?
90
90
 
91
91
  attr_reader reversed_at: Integer?
92
92
 
93
- def reversed_at=: (Integer) -> Integer
93
+ def reversed_at=: (Integer?) -> Integer?
94
94
 
95
95
  def initialize: (
96
96
  id: String,
@@ -103,13 +103,13 @@ module GrowsurfRuby
103
103
  ?amount_in_campaign_currency: Integer?,
104
104
  ?campaign_currency_iso: String?,
105
105
  ?exchange_rate: Float?,
106
- ?exchange_rate_at: Integer,
107
- ?failed_at: Integer,
106
+ ?exchange_rate_at: Integer?,
107
+ ?failed_at: Integer?,
108
108
  ?fx_error: String?,
109
- ?issued_at: Integer,
109
+ ?issued_at: Integer?,
110
110
  ?provider: String?,
111
- ?queued_at: Integer,
112
- ?reversed_at: Integer
111
+ ?queued_at: Integer?,
112
+ ?reversed_at: Integer?
113
113
  ) -> void
114
114
 
115
115
  def to_hash: -> {
@@ -123,13 +123,13 @@ module GrowsurfRuby
123
123
  amount_in_campaign_currency: Integer?,
124
124
  campaign_currency_iso: String?,
125
125
  exchange_rate: Float?,
126
- exchange_rate_at: Integer,
127
- failed_at: Integer,
126
+ exchange_rate_at: Integer?,
127
+ failed_at: Integer?,
128
128
  fx_error: String?,
129
- issued_at: Integer,
129
+ issued_at: Integer?,
130
130
  provider: String?,
131
- queued_at: Integer,
132
- reversed_at: Integer
131
+ queued_at: Integer?,
132
+ reversed_at: Integer?
133
133
  }
134
134
 
135
135
  type status = :UPCOMING | :QUEUED | :ISSUED | :FAILED | :REVERSED
@@ -1,6 +1,10 @@
1
1
  module GrowsurfRuby
2
2
  class AccountCreateParams = GrowsurfRuby::Models::AccountCreateParams
3
3
 
4
+ module AnalyticsAvailability = GrowsurfRuby::Models::AnalyticsAvailability
5
+
6
+ module AnalyticsUnavailableReason = GrowsurfRuby::Models::AnalyticsUnavailableReason
7
+
4
8
  class AffiliateApplication = GrowsurfRuby::Models::AffiliateApplication
5
9
 
6
10
  class AffiliateInvite = GrowsurfRuby::Models::AffiliateInvite
@@ -39,6 +43,8 @@ module GrowsurfRuby
39
43
 
40
44
  class CampaignRetrieveAffiliateApplicationParams = GrowsurfRuby::Models::CampaignRetrieveAffiliateApplicationParams
41
45
 
46
+ class CampaignRetrieveActivationAnalyticsParams = GrowsurfRuby::Models::CampaignRetrieveActivationAnalyticsParams
47
+
42
48
  class CampaignRetrieveAnalyticsParams = GrowsurfRuby::Models::CampaignRetrieveAnalyticsParams
43
49
 
44
50
  class CampaignRetrieveParams = GrowsurfRuby::Models::CampaignRetrieveParams
@@ -2,6 +2,25 @@ module GrowsurfRuby
2
2
  module Resources
3
3
  class Campaign
4
4
  class Design
5
+ # Icon configuration for the participant Resources destination.
6
+ type resources_icon = {
7
+ type?: "DEFAULT" | "IMAGE" | "NONE",
8
+ imageUrl?: String
9
+ }
10
+
11
+ # Participant presentation settings for Resources. Each label is limited to 100
12
+ # characters; imageUrl is limited to 500. Resource items use Program Resources operations.
13
+ type resources = {
14
+ isPublicDisplayed?: bool,
15
+ title?: String,
16
+ viewResourcesLinkText?: String,
17
+ backLinkText?: String,
18
+ copyButtonText?: String,
19
+ copiedText?: String,
20
+ emptyState?: String,
21
+ icon?: resources_icon
22
+ }
23
+
5
24
  def retrieve: (
6
25
  String id,
7
26
  ?request_options: GrowsurfRuby::request_opts
@@ -0,0 +1,14 @@
1
+ module GrowsurfRuby
2
+ module Resources
3
+ class Campaign
4
+ class Integrations
5
+ def list: (
6
+ String id,
7
+ ?request_options: GrowsurfRuby::request_opts
8
+ ) -> GrowsurfRuby::Models::Campaign::IntegrationListResponse
9
+
10
+ def initialize: (client: GrowsurfRuby::Client) -> void
11
+ end
12
+ end
13
+ end
14
+ end
@@ -118,6 +118,8 @@ module GrowsurfRuby
118
118
  ?total_tax_amounts: ::Array[::Hash[Symbol, top]],
119
119
  ?total_taxes: ::Array[::Hash[Symbol, top]],
120
120
  ?transaction_id: String,
121
+ ?payment_provider: String,
122
+ ?test_mode: bool,
121
123
  ?request_options: GrowsurfRuby::request_opts
122
124
  ) -> GrowsurfRuby::Models::Campaign::participant_record_transaction_response
123
125
 
@@ -139,6 +141,8 @@ module GrowsurfRuby
139
141
  ?refund_id: String,
140
142
  ?refund_status: String,
141
143
  ?transaction_id: String,
144
+ ?payment_provider: String,
145
+ ?test_mode: bool,
142
146
  ?request_options: GrowsurfRuby::request_opts
143
147
  ) -> GrowsurfRuby::Models::Campaign::ParticipantRefundTransactionResponse
144
148
 
@@ -0,0 +1,58 @@
1
+ module GrowsurfRuby
2
+ module Resources
3
+ class Campaign
4
+ class ProgramResources
5
+ def list: (
6
+ String id,
7
+ ?request_options: GrowsurfRuby::request_opts
8
+ ) -> GrowsurfRuby::Campaign::ProgramResourceListResponse
9
+
10
+ def create: (
11
+ String id,
12
+ type: GrowsurfRuby::Campaign::ProgramResourceCreateParams::type_,
13
+ title: String,
14
+ ?description: String?,
15
+ ?category: String?,
16
+ ?is_published: bool,
17
+ ?url: String,
18
+ ?text: String,
19
+ ?upload_ticket: String,
20
+ ?upload_result: GrowsurfRuby::Campaign::ProgramResourceUploadResult | GrowsurfRuby::Campaign::program_resource_upload_result,
21
+ ?request_options: GrowsurfRuby::request_opts
22
+ ) -> GrowsurfRuby::Campaign::ProgramResource
23
+
24
+ def update: (
25
+ String resource_id,
26
+ id: String,
27
+ ?type: GrowsurfRuby::Campaign::ProgramResourceUpdateParams::type_,
28
+ ?title: String,
29
+ ?description: String?,
30
+ ?category: String?,
31
+ ?is_published: bool,
32
+ ?position: Integer,
33
+ ?url: String,
34
+ ?text: String,
35
+ ?upload_ticket: String,
36
+ ?upload_result: GrowsurfRuby::Campaign::ProgramResourceUploadResult | GrowsurfRuby::Campaign::program_resource_upload_result,
37
+ ?request_options: GrowsurfRuby::request_opts
38
+ ) -> GrowsurfRuby::Campaign::ProgramResource
39
+
40
+ def delete: (
41
+ String resource_id,
42
+ id: String,
43
+ ?request_options: GrowsurfRuby::request_opts
44
+ ) -> GrowsurfRuby::Campaign::DeleteProgramResourceResponse
45
+
46
+ def create_upload_ticket: (
47
+ String id,
48
+ file_name: String,
49
+ mime_type: String,
50
+ bytes: Integer,
51
+ ?request_options: GrowsurfRuby::request_opts
52
+ ) -> GrowsurfRuby::Campaign::ProgramResourceUploadTicket
53
+
54
+ def initialize: (client: GrowsurfRuby::Client) -> void
55
+ end
56
+ end
57
+ end
58
+ end
@@ -12,20 +12,21 @@ module GrowsurfRuby
12
12
  type: GrowsurfRuby::Models::Campaign::RewardCreateParams::type_,
13
13
  ?commission_structure: GrowsurfRuby::CommissionStructure,
14
14
  ?conversions_required: Integer,
15
- ?coupon_code: String,
15
+ ?coupon_code: String?,
16
16
  ?description: String,
17
- ?image_url: String,
17
+ ?event: GrowsurfRuby::Models::Campaign::RewardCreateParams::event,
18
+ ?image_url: String?,
18
19
  ?is_unlimited: bool,
19
20
  ?is_visible: bool,
20
21
  ?limit: Integer,
21
22
  ?limit_duration: GrowsurfRuby::Models::Campaign::RewardCreateParams::limit_duration,
22
23
  ?metadata: ::Hash[Symbol, top],
23
- ?next_milestone_prefix: String,
24
- ?next_milestone_suffix: String,
24
+ ?next_milestone_prefix: String?,
25
+ ?next_milestone_suffix: String?,
25
26
  ?number_of_winners: Integer,
26
27
  ?order: Integer,
27
- ?referral_coupon_code: String,
28
- ?referral_description: String,
28
+ ?referral_coupon_code: String?,
29
+ ?referral_description: String?,
29
30
  ?referred_reward_upfront: bool,
30
31
  ?referred_value: GrowsurfRuby::RewardTaxValuation,
31
32
  ?title: String,
@@ -38,20 +39,21 @@ module GrowsurfRuby
38
39
  id: String,
39
40
  ?commission_structure: GrowsurfRuby::CommissionStructure,
40
41
  ?conversions_required: Integer,
41
- ?coupon_code: String,
42
+ ?coupon_code: String?,
42
43
  ?description: String,
43
- ?image_url: String,
44
+ ?event: GrowsurfRuby::Models::Campaign::RewardUpdateParams::event,
45
+ ?image_url: String?,
44
46
  ?is_unlimited: bool,
45
47
  ?is_visible: bool,
46
48
  ?limit: Integer,
47
49
  ?limit_duration: GrowsurfRuby::Models::Campaign::RewardUpdateParams::limit_duration,
48
50
  ?metadata: ::Hash[Symbol, top],
49
- ?next_milestone_prefix: String,
50
- ?next_milestone_suffix: String,
51
+ ?next_milestone_prefix: String?,
52
+ ?next_milestone_suffix: String?,
51
53
  ?number_of_winners: Integer,
52
54
  ?order: Integer,
53
- ?referral_coupon_code: String,
54
- ?referral_description: String,
55
+ ?referral_coupon_code: String?,
56
+ ?referral_description: String?,
55
57
  ?referred_reward_upfront: bool,
56
58
  ?referred_value: GrowsurfRuby::RewardTaxValuation,
57
59
  ?title: String,
@@ -9,6 +9,8 @@ module GrowsurfRuby
9
9
 
10
10
  attr_reader rewards: GrowsurfRuby::Resources::Campaign::Rewards
11
11
 
12
+ attr_reader resources: GrowsurfRuby::Resources::Campaign::ProgramResources
13
+
12
14
  attr_reader design: GrowsurfRuby::Resources::Campaign::Design
13
15
 
14
16
  attr_reader emails: GrowsurfRuby::Resources::Campaign::Emails
@@ -17,6 +19,8 @@ module GrowsurfRuby
17
19
 
18
20
  attr_reader installation: GrowsurfRuby::Resources::Campaign::Installation
19
21
 
22
+ attr_reader integrations: GrowsurfRuby::Resources::Campaign::Integrations
23
+
20
24
  attr_reader webhooks: GrowsurfRuby::Resources::Campaign::Webhooks
21
25
 
22
26
  def retrieve: (
@@ -33,6 +37,7 @@ module GrowsurfRuby
33
37
  ?company_logo_image_url: String,
34
38
  ?company_name: String,
35
39
  ?currency_iso: String,
40
+ ?goal: GrowsurfRuby::Models::CampaignCreateParams::goal,
36
41
  ?name: String,
37
42
  ?rewards: ::Array[GrowsurfRuby::Campaign::RewardCreateParams],
38
43
  ?request_options: GrowsurfRuby::request_opts
@@ -154,10 +159,22 @@ module GrowsurfRuby
154
159
  ?end_date: Integer,
155
160
  ?include: String,
156
161
  ?interval: GrowsurfRuby::Models::CampaignRetrieveAnalyticsParams::interval,
162
+ ?platform: GrowsurfRuby::Models::CampaignRetrieveAnalyticsParams::platform,
157
163
  ?start_date: Integer,
164
+ ?timezone: String,
158
165
  ?request_options: GrowsurfRuby::request_opts
159
166
  ) -> GrowsurfRuby::Models::CampaignRetrieveAnalyticsResponse
160
167
 
168
+ def retrieve_activation_analytics: (
169
+ String id,
170
+ ?cohort_from: Integer,
171
+ ?cohort_to: Integer,
172
+ ?cohort_interval: GrowsurfRuby::Models::CampaignRetrieveActivationAnalyticsParams::cohort_interval,
173
+ ?observation_window_days: GrowsurfRuby::Models::CampaignRetrieveActivationAnalyticsParams::observation_window_days,
174
+ ?timezone: String,
175
+ ?request_options: GrowsurfRuby::request_opts
176
+ ) -> GrowsurfRuby::Models::CampaignActivationAnalyticsResponse
177
+
161
178
  def review_affiliate_application: (
162
179
  String application_id,
163
180
  id: String,