tremendous_ruby 5.25.0 → 5.28.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/lib/tremendous/api/tremendous_api.rb +163 -9
- data/lib/tremendous/api_client.rb +3 -2
- data/lib/tremendous/configuration.rb +10 -0
- data/lib/tremendous/models/campaign.rb +3 -5
- data/lib/tremendous/models/campaign_base.rb +3 -5
- data/lib/tremendous/models/connected_organization_member_member.rb +6 -4
- data/lib/tremendous/models/connected_organization_member_session.rb +27 -1
- data/lib/tremendous/models/connected_organization_organization.rb +3 -5
- data/lib/tremendous/models/{generate_reward_token200_response_reward.rb → create_api_key_request.rb} +51 -53
- data/lib/tremendous/models/create_campaign_request.rb +3 -5
- data/lib/tremendous/models/create_connected_organization_member_session200_response_connected_organization_member_session.rb +27 -1
- data/lib/tremendous/models/create_connected_organization_member_session_request.rb +33 -4
- data/lib/tremendous/models/create_connected_organization_request.rb +13 -4
- data/lib/tremendous/models/{create_report201_response_report.rb → create_connected_organization_request_kyb_prefill.rb} +102 -81
- data/lib/tremendous/models/create_field.rb +6 -4
- data/lib/tremendous/models/create_field_request.rb +6 -4
- data/lib/tremendous/models/create_invoice_request.rb +6 -10
- data/lib/tremendous/models/create_order200_response_order.rb +9 -9
- data/lib/tremendous/models/create_order200_response_order_rewards_inner_delivery.rb +12 -8
- data/lib/tremendous/models/create_report200_response_report.rb +3 -5
- data/lib/tremendous/models/create_report_request.rb +12 -8
- data/lib/tremendous/models/create_report_request_filters_digital_rewards.rb +6 -10
- data/lib/tremendous/models/delivery_details.rb +6 -10
- data/lib/tremendous/models/delivery_details_with_link.rb +12 -8
- data/lib/tremendous/models/field.rb +3 -5
- data/lib/tremendous/models/fraud_config_country.rb +6 -4
- data/lib/tremendous/models/fraud_config_redeemed_rewards_amount.rb +6 -4
- data/lib/tremendous/models/fraud_config_redeemed_rewards_count.rb +6 -4
- data/lib/tremendous/models/{create_campaign201_response.rb → fraud_config_review_vpn.rb} +21 -19
- data/lib/tremendous/models/fraud_review.rb +10 -16
- data/lib/tremendous/models/fraud_review_base.rb +7 -11
- data/lib/tremendous/models/fraud_review_list_item.rb +7 -11
- data/lib/tremendous/models/fraud_review_reason.rb +2 -1
- data/lib/tremendous/models/fraud_rule_request_config.rb +2 -1
- data/lib/tremendous/models/fraud_rules_list_item.rb +4 -6
- data/lib/tremendous/models/funding_source.rb +12 -14
- data/lib/tremendous/models/get_fraud_review200_response_fraud_review.rb +10 -16
- data/lib/tremendous/models/get_member200_response_member.rb +6 -4
- data/lib/tremendous/models/get_member200_response_member_events_inner.rb +3 -5
- data/lib/tremendous/models/invoice.rb +12 -14
- data/lib/tremendous/models/list_campaigns200_response_campaigns_inner.rb +3 -5
- data/lib/tremendous/models/list_connected_organization_members200_response_connected_organization_members_inner_member.rb +6 -4
- data/lib/tremendous/models/list_connected_organizations200_response_connected_organizations_inner_organization.rb +3 -5
- data/lib/tremendous/models/list_fields200_response_fields_inner.rb +3 -5
- data/lib/tremendous/models/list_fraud_reviews200_response_fraud_reviews_inner.rb +7 -11
- data/lib/tremendous/models/list_fraud_rules200_response_fraud_rules_inner.rb +4 -6
- data/lib/tremendous/models/list_funding_sources200_response_funding_sources_inner.rb +12 -14
- data/lib/tremendous/models/list_funding_sources200_response_funding_sources_inner_meta.rb +6 -10
- data/lib/tremendous/models/list_invoices200_response_invoices_inner.rb +12 -14
- data/lib/tremendous/models/list_members200_response_members_inner.rb +6 -4
- data/lib/tremendous/models/list_orders200_response_orders_inner.rb +9 -9
- data/lib/tremendous/models/list_organizations200_response_organizations_inner.rb +3 -5
- data/lib/tremendous/models/list_products_response_products_inner.rb +11 -11
- data/lib/tremendous/models/list_products_response_products_inner_images_inner.rb +6 -4
- data/lib/tremendous/models/list_rewards200_response_rewards_inner_delivery.rb +6 -10
- data/lib/tremendous/models/list_rewards200_response_rewards_inner_value.rb +3 -5
- data/lib/tremendous/models/member.rb +6 -4
- data/lib/tremendous/models/member_base.rb +6 -4
- data/lib/tremendous/models/member_with_events.rb +6 -4
- data/lib/tremendous/models/member_without_events.rb +6 -4
- data/lib/tremendous/models/order.rb +9 -9
- data/lib/tremendous/models/order_base.rb +9 -9
- data/lib/tremendous/models/order_with_link.rb +9 -9
- data/lib/tremendous/models/order_without_link.rb +9 -9
- data/lib/tremendous/models/organization.rb +3 -5
- data/lib/tremendous/models/payout.rb +3 -5
- data/lib/tremendous/models/product.rb +11 -11
- data/lib/tremendous/models/report.rb +3 -5
- data/lib/tremendous/models/review_country.rb +6 -4
- data/lib/tremendous/models/review_redeemed_rewards_amount.rb +6 -4
- data/lib/tremendous/models/review_redeemed_rewards_count.rb +6 -4
- data/lib/tremendous/models/{generate_reward_token200_response.rb → review_vpn.rb} +22 -19
- data/lib/tremendous/models/reward_value.rb +3 -5
- data/lib/tremendous/models/reward_with_link_delivery.rb +12 -8
- data/lib/tremendous/models/reward_without_link_delivery.rb +6 -10
- data/lib/tremendous/models/single_reward_order_reward_delivery.rb +3 -5
- data/lib/tremendous/models/single_reward_order_with_link_order.rb +9 -9
- data/lib/tremendous/models/single_reward_order_without_link_order.rb +9 -9
- data/lib/tremendous/models/update_campaign.rb +3 -5
- data/lib/tremendous/models/update_campaign_request.rb +3 -5
- data/lib/tremendous/models/update_fraud_rule_list_request.rb +6 -4
- data/lib/tremendous/models/{get_fraud_review200_response_fraud_review_geo.rb → update_member.rb} +28 -32
- data/lib/tremendous/models/{create_report201_response.rb → update_member_request.rb} +34 -27
- data/lib/tremendous/version.rb +1 -1
- data/lib/tremendous.rb +6 -0
- metadata +21 -8
- data/lib/tremendous/models/create_order201_response.rb +0 -221
|
@@ -24,7 +24,7 @@ module Tremendous
|
|
|
24
24
|
# Detailed description of the product.
|
|
25
25
|
attr_accessor :description
|
|
26
26
|
|
|
27
|
-
# The category of the product <table> <thead> <tr> <th>Category</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code>ach</code></td> <td>Bank transfer to the recipient</td> </tr> <tr> <td><code>charity</code></td> <td>Donations to a charity</td> </tr> <tr> <td><code>instant_debit_transfer</code></td> <td>Instant debit transfer to the recipient</td> </tr> <tr> <td><code>merchant_card</code></td> <td>A gift card for a certain merchant (e.g. Amazon)</td> </tr> <tr> <td><code>paypal</code></td> <td>Payout via PayPal</td> </tr> <tr> <td><code>venmo</code></td> <td>Payout via Venmo</td> </tr> <tr> <td><code>visa_card</code></td> <td>Payout in form of a Visa debit card</td> </tr> <tr> <td><code>cash_app</code></td> <td>Payout via Cash App</td> </tr> <tr> <td><code>international_bank</code></td> <td>Bank transfer to recipients outside of the US</td> </tr> </tbody> </table>
|
|
27
|
+
# The category of the product <table> <thead> <tr> <th>Category</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code>ach</code></td> <td>Bank transfer to the recipient</td> </tr> <tr> <td><code>charity</code></td> <td>Donations to a charity</td> </tr> <tr> <td><code>instant_debit_transfer</code></td> <td>Instant debit transfer to the recipient</td> </tr> <tr> <td><code>merchant_card</code></td> <td>A gift card for a certain merchant (e.g. Amazon)</td> </tr> <tr> <td><code>paypal</code></td> <td>Payout via PayPal</td> </tr> <tr> <td><code>venmo</code></td> <td>Payout via Venmo</td> </tr> <tr> <td><code>visa_card</code></td> <td>Payout in form of a Visa debit card</td> </tr> <tr> <td><code>cash_app</code></td> <td>Payout via Cash App</td> </tr> <tr> <td><code>international_bank</code></td> <td>Bank transfer to recipients outside of the US</td> </tr> <tr> <td><code>wallet</code></td> <td>Payout to a digital wallet (e.g. GCash, MoMo)</td> </tr> </tbody> </table>
|
|
28
28
|
attr_accessor :category
|
|
29
29
|
|
|
30
30
|
# Additional classification for the product. Only applicable to products with a `category` of `merchant_card`. Possible subcategories: * `beauty_and_health` * `digital_financial_services` * `electronics` * `entertainment` * `fashion` * `food_and_drink` * `general_merchandise` * `grocery_and_supermarkets` * `home_and_living` * `mobility_and_fuel` * `sports_and_outdoor_gear` * `travel_and_hospitality`
|
|
@@ -280,7 +280,7 @@ module Tremendous
|
|
|
280
280
|
return false if @name.nil?
|
|
281
281
|
return false if @description.nil?
|
|
282
282
|
return false if @category.nil?
|
|
283
|
-
category_validator = EnumAttributeValidator.new('String', ["ach", "charity", "instant_debit_transfer", "merchant_card", "paypal", "venmo", "visa_card", "cash_app", "international_bank"])
|
|
283
|
+
category_validator = EnumAttributeValidator.new('String', ["ach", "charity", "instant_debit_transfer", "merchant_card", "paypal", "venmo", "visa_card", "cash_app", "international_bank", "wallet"])
|
|
284
284
|
return false unless category_validator.valid?(@category)
|
|
285
285
|
subcategory_validator = EnumAttributeValidator.new('String', ["beauty_and_health", "digital_financial_services", "electronics", "entertainment", "fashion", "food_and_drink", "general_merchandise", "grocery_and_supermarkets", "home_and_living", "mobility_and_fuel", "sports_and_outdoor_gear", "travel_and_hospitality"])
|
|
286
286
|
return false unless subcategory_validator.valid?(@subcategory)
|
|
@@ -329,23 +329,23 @@ module Tremendous
|
|
|
329
329
|
@description = description
|
|
330
330
|
end
|
|
331
331
|
|
|
332
|
-
# Custom attribute writer method
|
|
332
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
333
|
+
# so that enum values added to the API don't break deserialization on
|
|
334
|
+
# older versions of this gem.
|
|
333
335
|
# @param [Object] category Object to be assigned
|
|
334
336
|
def category=(category)
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
fail ArgumentError, "invalid value for \"category\", must be one of #{validator.allowable_values}."
|
|
337
|
+
if category.nil?
|
|
338
|
+
fail ArgumentError, 'category cannot be nil'
|
|
338
339
|
end
|
|
340
|
+
|
|
339
341
|
@category = category
|
|
340
342
|
end
|
|
341
343
|
|
|
342
|
-
# Custom attribute writer method
|
|
344
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
345
|
+
# so that enum values added to the API don't break deserialization on
|
|
346
|
+
# older versions of this gem.
|
|
343
347
|
# @param [Object] subcategory Object to be assigned
|
|
344
348
|
def subcategory=(subcategory)
|
|
345
|
-
validator = EnumAttributeValidator.new('String', ["beauty_and_health", "digital_financial_services", "electronics", "entertainment", "fashion", "food_and_drink", "general_merchandise", "grocery_and_supermarkets", "home_and_living", "mobility_and_fuel", "sports_and_outdoor_gear", "travel_and_hospitality"])
|
|
346
|
-
unless validator.valid?(subcategory)
|
|
347
|
-
fail ArgumentError, "invalid value for \"subcategory\", must be one of #{validator.allowable_values}."
|
|
348
|
-
end
|
|
349
349
|
@subcategory = subcategory
|
|
350
350
|
end
|
|
351
351
|
|
|
@@ -146,13 +146,11 @@ module Tremendous
|
|
|
146
146
|
true
|
|
147
147
|
end
|
|
148
148
|
|
|
149
|
-
# Custom attribute writer method
|
|
149
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
150
|
+
# so that enum values added to the API don't break deserialization on
|
|
151
|
+
# older versions of this gem.
|
|
150
152
|
# @param [Object] status Object to be assigned
|
|
151
153
|
def status=(status)
|
|
152
|
-
validator = EnumAttributeValidator.new('String', ["CREATED", "PROCESSING", "READY_FOR_DOWNLOAD", "FAILED"])
|
|
153
|
-
unless validator.valid?(status)
|
|
154
|
-
fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
|
|
155
|
-
end
|
|
156
154
|
@status = status
|
|
157
155
|
end
|
|
158
156
|
|
|
@@ -134,13 +134,15 @@ module Tremendous
|
|
|
134
134
|
true
|
|
135
135
|
end
|
|
136
136
|
|
|
137
|
-
# Custom attribute writer method
|
|
137
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
138
|
+
# so that enum values added to the API don't break deserialization on
|
|
139
|
+
# older versions of this gem.
|
|
138
140
|
# @param [Object] type Object to be assigned
|
|
139
141
|
def type=(type)
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
fail ArgumentError, "invalid value for \"type\", must be one of #{validator.allowable_values}."
|
|
142
|
+
if type.nil?
|
|
143
|
+
fail ArgumentError, 'type cannot be nil'
|
|
143
144
|
end
|
|
145
|
+
|
|
144
146
|
@type = type
|
|
145
147
|
end
|
|
146
148
|
|
|
@@ -151,13 +151,15 @@ module Tremendous
|
|
|
151
151
|
@amount = amount
|
|
152
152
|
end
|
|
153
153
|
|
|
154
|
-
# Custom attribute writer method
|
|
154
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
155
|
+
# so that enum values added to the API don't break deserialization on
|
|
156
|
+
# older versions of this gem.
|
|
155
157
|
# @param [Object] period Object to be assigned
|
|
156
158
|
def period=(period)
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
fail ArgumentError, "invalid value for \"period\", must be one of #{validator.allowable_values}."
|
|
159
|
+
if period.nil?
|
|
160
|
+
fail ArgumentError, 'period cannot be nil'
|
|
160
161
|
end
|
|
162
|
+
|
|
161
163
|
@period = period
|
|
162
164
|
end
|
|
163
165
|
|
|
@@ -151,13 +151,15 @@ module Tremendous
|
|
|
151
151
|
@amount = amount
|
|
152
152
|
end
|
|
153
153
|
|
|
154
|
-
# Custom attribute writer method
|
|
154
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
155
|
+
# so that enum values added to the API don't break deserialization on
|
|
156
|
+
# older versions of this gem.
|
|
155
157
|
# @param [Object] period Object to be assigned
|
|
156
158
|
def period=(period)
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
fail ArgumentError, "invalid value for \"period\", must be one of #{validator.allowable_values}."
|
|
159
|
+
if period.nil?
|
|
160
|
+
fail ArgumentError, 'period cannot be nil'
|
|
160
161
|
end
|
|
162
|
+
|
|
161
163
|
@period = period
|
|
162
164
|
end
|
|
163
165
|
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
The version of the OpenAPI document: 2
|
|
7
7
|
Contact: developers@tremendous.com
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
|
-
Generator version: 7.
|
|
9
|
+
Generator version: 7.12.0
|
|
10
10
|
|
|
11
11
|
=end
|
|
12
12
|
|
|
@@ -14,25 +14,32 @@ require 'date'
|
|
|
14
14
|
require 'time'
|
|
15
15
|
|
|
16
16
|
module Tremendous
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
# Flag rewards redeemed through VPN or proxy traffic. By default, Apple Private Relay traffic is flagged; set `skip_apple_private_relay` to true to exclude it.
|
|
18
|
+
class ReviewVpn
|
|
19
|
+
# Whether Apple Private Relay traffic should be excluded from VPN fraud review. When omitted or false, Apple Private Relay traffic is flagged with other VPN and proxy traffic.
|
|
20
|
+
attr_accessor :skip_apple_private_relay
|
|
19
21
|
|
|
20
22
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
21
23
|
def self.attribute_map
|
|
22
24
|
{
|
|
23
|
-
:'
|
|
25
|
+
:'skip_apple_private_relay' => :'skip_apple_private_relay'
|
|
24
26
|
}
|
|
25
27
|
end
|
|
26
28
|
|
|
29
|
+
# Returns attribute mapping this model knows about
|
|
30
|
+
def self.acceptable_attribute_map
|
|
31
|
+
attribute_map
|
|
32
|
+
end
|
|
33
|
+
|
|
27
34
|
# Returns all the JSON keys this model knows about
|
|
28
35
|
def self.acceptable_attributes
|
|
29
|
-
|
|
36
|
+
acceptable_attribute_map.values
|
|
30
37
|
end
|
|
31
38
|
|
|
32
39
|
# Attribute type mapping.
|
|
33
40
|
def self.openapi_types
|
|
34
41
|
{
|
|
35
|
-
:'
|
|
42
|
+
:'skip_apple_private_relay' => :'Boolean'
|
|
36
43
|
}
|
|
37
44
|
end
|
|
38
45
|
|
|
@@ -46,21 +53,22 @@ module Tremendous
|
|
|
46
53
|
# @param [Hash] attributes Model attributes in the form of hash
|
|
47
54
|
def initialize(attributes = {})
|
|
48
55
|
if (!attributes.is_a?(Hash))
|
|
49
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `Tremendous::
|
|
56
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Tremendous::ReviewVpn` initialize method"
|
|
50
57
|
end
|
|
51
58
|
|
|
52
59
|
# check to see if the attribute exists and convert string to symbol for hash key
|
|
60
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
53
61
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
54
|
-
if (!
|
|
55
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `Tremendous::
|
|
62
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
63
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Tremendous::ReviewVpn`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
56
64
|
end
|
|
57
65
|
h[k.to_sym] = v
|
|
58
66
|
}
|
|
59
67
|
|
|
60
|
-
if attributes.key?(:'
|
|
61
|
-
self.
|
|
68
|
+
if attributes.key?(:'skip_apple_private_relay')
|
|
69
|
+
self.skip_apple_private_relay = attributes[:'skip_apple_private_relay']
|
|
62
70
|
else
|
|
63
|
-
self.
|
|
71
|
+
self.skip_apple_private_relay = false
|
|
64
72
|
end
|
|
65
73
|
end
|
|
66
74
|
|
|
@@ -69,10 +77,6 @@ module Tremendous
|
|
|
69
77
|
def list_invalid_properties
|
|
70
78
|
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
71
79
|
invalid_properties = Array.new
|
|
72
|
-
if @reward.nil?
|
|
73
|
-
invalid_properties.push('invalid value for "reward", reward cannot be nil.')
|
|
74
|
-
end
|
|
75
|
-
|
|
76
80
|
invalid_properties
|
|
77
81
|
end
|
|
78
82
|
|
|
@@ -80,7 +84,6 @@ module Tremendous
|
|
|
80
84
|
# @return true if the model is valid
|
|
81
85
|
def valid?
|
|
82
86
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
83
|
-
return false if @reward.nil?
|
|
84
87
|
true
|
|
85
88
|
end
|
|
86
89
|
|
|
@@ -89,7 +92,7 @@ module Tremendous
|
|
|
89
92
|
def ==(o)
|
|
90
93
|
return true if self.equal?(o)
|
|
91
94
|
self.class == o.class &&
|
|
92
|
-
|
|
95
|
+
skip_apple_private_relay == o.skip_apple_private_relay
|
|
93
96
|
end
|
|
94
97
|
|
|
95
98
|
# @see the `==` method
|
|
@@ -101,7 +104,7 @@ module Tremendous
|
|
|
101
104
|
# Calculates hash code according to all attributes.
|
|
102
105
|
# @return [Integer] Hash code
|
|
103
106
|
def hash
|
|
104
|
-
[
|
|
107
|
+
[skip_apple_private_relay].hash
|
|
105
108
|
end
|
|
106
109
|
|
|
107
110
|
# Builds the object from hash
|
|
@@ -134,13 +134,11 @@ module Tremendous
|
|
|
134
134
|
@denomination = denomination
|
|
135
135
|
end
|
|
136
136
|
|
|
137
|
-
# Custom attribute writer method
|
|
137
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
138
|
+
# so that enum values added to the API don't break deserialization on
|
|
139
|
+
# older versions of this gem.
|
|
138
140
|
# @param [Object] currency_code Object to be assigned
|
|
139
141
|
def currency_code=(currency_code)
|
|
140
|
-
validator = EnumAttributeValidator.new('String', ["USD", "CAD", "EUR", "AED", "AFN", "ALL", "AMD", "ARS", "AUD", "AZN", "BAM", "BDT", "BHD", "BIF", "BND", "BOB", "BRL", "BWP", "BYN", "BZD", "CDF", "CHF", "CLP", "CNY", "COP", "CRC", "CVE", "CZK", "DJF", "DKK", "DOP", "DZD", "EGP", "ERN", "ETB", "GBP", "GEL", "GHS", "GNF", "GTQ", "HKD", "HNL", "HRK", "HUF", "IDR", "ILS", "INR", "IQD", "IRR", "ISK", "JMD", "JOD", "JPY", "KES", "KHR", "KRW", "KWD", "KZT", "LBP", "LKR", "MAD", "MDL", "MGA", "MKD", "MMK", "MOP", "MUR", "MXN", "MYR", "MZN", "NAD", "NGN", "NIO", "NOK", "NPR", "NZD", "OMR", "PAB", "PEN", "PHP", "PKR", "PLN", "PYG", "QAR", "RON", "RSD", "RUB", "RWF", "SAR", "SDG", "SEK", "SGD", "SOS", "SYP", "THB", "TND", "TOP", "TRY", "TTD", "TWD", "TZS", "UAH", "UGX", "UYU", "UZS", "VEF", "VND", "XAF", "XOF", "YER", "ZAR"])
|
|
141
|
-
unless validator.valid?(currency_code)
|
|
142
|
-
fail ArgumentError, "invalid value for \"currency_code\", must be one of #{validator.allowable_values}."
|
|
143
|
-
end
|
|
144
142
|
@currency_code = currency_code
|
|
145
143
|
end
|
|
146
144
|
|
|
@@ -143,23 +143,27 @@ module Tremendous
|
|
|
143
143
|
true
|
|
144
144
|
end
|
|
145
145
|
|
|
146
|
-
# Custom attribute writer method
|
|
146
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
147
|
+
# so that enum values added to the API don't break deserialization on
|
|
148
|
+
# older versions of this gem.
|
|
147
149
|
# @param [Object] method Object to be assigned
|
|
148
150
|
def method=(method)
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
fail ArgumentError, "invalid value for \"method\", must be one of #{validator.allowable_values}."
|
|
151
|
+
if method.nil?
|
|
152
|
+
fail ArgumentError, 'method cannot be nil'
|
|
152
153
|
end
|
|
154
|
+
|
|
153
155
|
@method = method
|
|
154
156
|
end
|
|
155
157
|
|
|
156
|
-
# Custom attribute writer method
|
|
158
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
159
|
+
# so that enum values added to the API don't break deserialization on
|
|
160
|
+
# older versions of this gem.
|
|
157
161
|
# @param [Object] status Object to be assigned
|
|
158
162
|
def status=(status)
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
|
|
163
|
+
if status.nil?
|
|
164
|
+
fail ArgumentError, 'status cannot be nil'
|
|
162
165
|
end
|
|
166
|
+
|
|
163
167
|
@status = status
|
|
164
168
|
end
|
|
165
169
|
|
|
@@ -120,23 +120,19 @@ module Tremendous
|
|
|
120
120
|
true
|
|
121
121
|
end
|
|
122
122
|
|
|
123
|
-
# Custom attribute writer method
|
|
123
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
124
|
+
# so that enum values added to the API don't break deserialization on
|
|
125
|
+
# older versions of this gem.
|
|
124
126
|
# @param [Object] method Object to be assigned
|
|
125
127
|
def method=(method)
|
|
126
|
-
validator = EnumAttributeValidator.new('String', ["EMAIL", "LINK", "PHONE"])
|
|
127
|
-
unless validator.valid?(method)
|
|
128
|
-
fail ArgumentError, "invalid value for \"method\", must be one of #{validator.allowable_values}."
|
|
129
|
-
end
|
|
130
128
|
@method = method
|
|
131
129
|
end
|
|
132
130
|
|
|
133
|
-
# Custom attribute writer method
|
|
131
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
132
|
+
# so that enum values added to the API don't break deserialization on
|
|
133
|
+
# older versions of this gem.
|
|
134
134
|
# @param [Object] status Object to be assigned
|
|
135
135
|
def status=(status)
|
|
136
|
-
validator = EnumAttributeValidator.new('String', ["SCHEDULED", "FAILED", "SUCCEEDED", "PENDING"])
|
|
137
|
-
unless validator.valid?(status)
|
|
138
|
-
fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
|
|
139
|
-
end
|
|
140
136
|
@status = status
|
|
141
137
|
end
|
|
142
138
|
|
|
@@ -117,13 +117,11 @@ module Tremendous
|
|
|
117
117
|
true
|
|
118
118
|
end
|
|
119
119
|
|
|
120
|
-
# Custom attribute writer method
|
|
120
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
121
|
+
# so that enum values added to the API don't break deserialization on
|
|
122
|
+
# older versions of this gem.
|
|
121
123
|
# @param [Object] method Object to be assigned
|
|
122
124
|
def method=(method)
|
|
123
|
-
validator = EnumAttributeValidator.new('String', ["EMAIL", "LINK", "PHONE"])
|
|
124
|
-
unless validator.valid?(method)
|
|
125
|
-
fail ArgumentError, "invalid value for \"method\", must be one of #{validator.allowable_values}."
|
|
126
|
-
end
|
|
127
125
|
@method = method
|
|
128
126
|
end
|
|
129
127
|
|
|
@@ -254,23 +254,23 @@ module Tremendous
|
|
|
254
254
|
@created_at = created_at
|
|
255
255
|
end
|
|
256
256
|
|
|
257
|
-
# Custom attribute writer method
|
|
257
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
258
|
+
# so that enum values added to the API don't break deserialization on
|
|
259
|
+
# older versions of this gem.
|
|
258
260
|
# @param [Object] status Object to be assigned
|
|
259
261
|
def status=(status)
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
|
|
262
|
+
if status.nil?
|
|
263
|
+
fail ArgumentError, 'status cannot be nil'
|
|
263
264
|
end
|
|
265
|
+
|
|
264
266
|
@status = status
|
|
265
267
|
end
|
|
266
268
|
|
|
267
|
-
# Custom attribute writer method
|
|
269
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
270
|
+
# so that enum values added to the API don't break deserialization on
|
|
271
|
+
# older versions of this gem.
|
|
268
272
|
# @param [Object] channel Object to be assigned
|
|
269
273
|
def channel=(channel)
|
|
270
|
-
validator = EnumAttributeValidator.new('String', ["UI", "API", "EMBED", "DECIPHER", "QUALTRICS", "TYPEFORM", "SURVEY MONKEY", "YOTPO"])
|
|
271
|
-
unless validator.valid?(channel)
|
|
272
|
-
fail ArgumentError, "invalid value for \"channel\", must be one of #{validator.allowable_values}."
|
|
273
|
-
end
|
|
274
274
|
@channel = channel
|
|
275
275
|
end
|
|
276
276
|
|
|
@@ -254,23 +254,23 @@ module Tremendous
|
|
|
254
254
|
@created_at = created_at
|
|
255
255
|
end
|
|
256
256
|
|
|
257
|
-
# Custom attribute writer method
|
|
257
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
258
|
+
# so that enum values added to the API don't break deserialization on
|
|
259
|
+
# older versions of this gem.
|
|
258
260
|
# @param [Object] status Object to be assigned
|
|
259
261
|
def status=(status)
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
|
|
262
|
+
if status.nil?
|
|
263
|
+
fail ArgumentError, 'status cannot be nil'
|
|
263
264
|
end
|
|
265
|
+
|
|
264
266
|
@status = status
|
|
265
267
|
end
|
|
266
268
|
|
|
267
|
-
# Custom attribute writer method
|
|
269
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
270
|
+
# so that enum values added to the API don't break deserialization on
|
|
271
|
+
# older versions of this gem.
|
|
268
272
|
# @param [Object] channel Object to be assigned
|
|
269
273
|
def channel=(channel)
|
|
270
|
-
validator = EnumAttributeValidator.new('String', ["UI", "API", "EMBED", "DECIPHER", "QUALTRICS", "TYPEFORM", "SURVEY MONKEY", "YOTPO"])
|
|
271
|
-
unless validator.valid?(channel)
|
|
272
|
-
fail ArgumentError, "invalid value for \"channel\", must be one of #{validator.allowable_values}."
|
|
273
|
-
end
|
|
274
274
|
@channel = channel
|
|
275
275
|
end
|
|
276
276
|
|
|
@@ -194,13 +194,11 @@ module Tremendous
|
|
|
194
194
|
@id = id
|
|
195
195
|
end
|
|
196
196
|
|
|
197
|
-
# Custom attribute writer method
|
|
197
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
198
|
+
# so that enum values added to the API don't break deserialization on
|
|
199
|
+
# older versions of this gem.
|
|
198
200
|
# @param [Object] fee_charged_to Object to be assigned
|
|
199
201
|
def fee_charged_to=(fee_charged_to)
|
|
200
|
-
validator = EnumAttributeValidator.new('String', ["SENDER", "RECIPIENT"])
|
|
201
|
-
unless validator.valid?(fee_charged_to)
|
|
202
|
-
fail ArgumentError, "invalid value for \"fee_charged_to\", must be one of #{validator.allowable_values}."
|
|
203
|
-
end
|
|
204
202
|
@fee_charged_to = fee_charged_to
|
|
205
203
|
end
|
|
206
204
|
|
|
@@ -165,13 +165,11 @@ module Tremendous
|
|
|
165
165
|
true
|
|
166
166
|
end
|
|
167
167
|
|
|
168
|
-
# Custom attribute writer method
|
|
168
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
169
|
+
# so that enum values added to the API don't break deserialization on
|
|
170
|
+
# older versions of this gem.
|
|
169
171
|
# @param [Object] fee_charged_to Object to be assigned
|
|
170
172
|
def fee_charged_to=(fee_charged_to)
|
|
171
|
-
validator = EnumAttributeValidator.new('String', ["SENDER", "RECIPIENT"])
|
|
172
|
-
unless validator.valid?(fee_charged_to)
|
|
173
|
-
fail ArgumentError, "invalid value for \"fee_charged_to\", must be one of #{validator.allowable_values}."
|
|
174
|
-
end
|
|
175
173
|
@fee_charged_to = fee_charged_to
|
|
176
174
|
end
|
|
177
175
|
|
|
@@ -130,13 +130,15 @@ module Tremendous
|
|
|
130
130
|
true
|
|
131
131
|
end
|
|
132
132
|
|
|
133
|
-
# Custom attribute writer method
|
|
133
|
+
# Custom attribute writer method for enum attributes. Any value is accepted
|
|
134
|
+
# so that enum values added to the API don't break deserialization on
|
|
135
|
+
# older versions of this gem.
|
|
134
136
|
# @param [Object] operation Object to be assigned
|
|
135
137
|
def operation=(operation)
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
fail ArgumentError, "invalid value for \"operation\", must be one of #{validator.allowable_values}."
|
|
138
|
+
if operation.nil?
|
|
139
|
+
fail ArgumentError, 'operation cannot be nil'
|
|
139
140
|
end
|
|
141
|
+
|
|
140
142
|
@operation = operation
|
|
141
143
|
end
|
|
142
144
|
|
data/lib/tremendous/models/{get_fraud_review200_response_fraud_review_geo.rb → update_member.rb}
RENAMED
|
@@ -14,23 +14,14 @@ require 'date'
|
|
|
14
14
|
require 'time'
|
|
15
15
|
|
|
16
16
|
module Tremendous
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
attr_accessor :ip
|
|
21
|
-
|
|
22
|
-
# The country code (ISO-3166 alpha-2 character code) linked to the recipient's IP.
|
|
23
|
-
attr_accessor :country
|
|
24
|
-
|
|
25
|
-
# The city associated with the recipient's IP.
|
|
26
|
-
attr_accessor :city
|
|
17
|
+
class UpdateMember
|
|
18
|
+
# The role ID to assign to the member within the organization.
|
|
19
|
+
attr_accessor :role
|
|
27
20
|
|
|
28
21
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
29
22
|
def self.attribute_map
|
|
30
23
|
{
|
|
31
|
-
:'
|
|
32
|
-
:'country' => :'country',
|
|
33
|
-
:'city' => :'city'
|
|
24
|
+
:'role' => :'role'
|
|
34
25
|
}
|
|
35
26
|
end
|
|
36
27
|
|
|
@@ -47,9 +38,7 @@ module Tremendous
|
|
|
47
38
|
# Attribute type mapping.
|
|
48
39
|
def self.openapi_types
|
|
49
40
|
{
|
|
50
|
-
:'
|
|
51
|
-
:'country' => :'String',
|
|
52
|
-
:'city' => :'String'
|
|
41
|
+
:'role' => :'String'
|
|
53
42
|
}
|
|
54
43
|
end
|
|
55
44
|
|
|
@@ -63,28 +52,22 @@ module Tremendous
|
|
|
63
52
|
# @param [Hash] attributes Model attributes in the form of hash
|
|
64
53
|
def initialize(attributes = {})
|
|
65
54
|
if (!attributes.is_a?(Hash))
|
|
66
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `Tremendous::
|
|
55
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Tremendous::UpdateMember` initialize method"
|
|
67
56
|
end
|
|
68
57
|
|
|
69
58
|
# check to see if the attribute exists and convert string to symbol for hash key
|
|
70
59
|
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
71
60
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
72
61
|
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
73
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `Tremendous::
|
|
62
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Tremendous::UpdateMember`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
74
63
|
end
|
|
75
64
|
h[k.to_sym] = v
|
|
76
65
|
}
|
|
77
66
|
|
|
78
|
-
if attributes.key?(:'
|
|
79
|
-
self.
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
if attributes.key?(:'country')
|
|
83
|
-
self.country = attributes[:'country']
|
|
84
|
-
end
|
|
85
|
-
|
|
86
|
-
if attributes.key?(:'city')
|
|
87
|
-
self.city = attributes[:'city']
|
|
67
|
+
if attributes.key?(:'role')
|
|
68
|
+
self.role = attributes[:'role']
|
|
69
|
+
else
|
|
70
|
+
self.role = nil
|
|
88
71
|
end
|
|
89
72
|
end
|
|
90
73
|
|
|
@@ -93,6 +76,10 @@ module Tremendous
|
|
|
93
76
|
def list_invalid_properties
|
|
94
77
|
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
95
78
|
invalid_properties = Array.new
|
|
79
|
+
if @role.nil?
|
|
80
|
+
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
|
81
|
+
end
|
|
82
|
+
|
|
96
83
|
invalid_properties
|
|
97
84
|
end
|
|
98
85
|
|
|
@@ -100,17 +87,26 @@ module Tremendous
|
|
|
100
87
|
# @return true if the model is valid
|
|
101
88
|
def valid?
|
|
102
89
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
90
|
+
return false if @role.nil?
|
|
103
91
|
true
|
|
104
92
|
end
|
|
105
93
|
|
|
94
|
+
# Custom attribute writer method with validation
|
|
95
|
+
# @param [Object] role Value to be assigned
|
|
96
|
+
def role=(role)
|
|
97
|
+
if role.nil?
|
|
98
|
+
fail ArgumentError, 'role cannot be nil'
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
@role = role
|
|
102
|
+
end
|
|
103
|
+
|
|
106
104
|
# Checks equality by comparing each attribute.
|
|
107
105
|
# @param [Object] Object to be compared
|
|
108
106
|
def ==(o)
|
|
109
107
|
return true if self.equal?(o)
|
|
110
108
|
self.class == o.class &&
|
|
111
|
-
|
|
112
|
-
country == o.country &&
|
|
113
|
-
city == o.city
|
|
109
|
+
role == o.role
|
|
114
110
|
end
|
|
115
111
|
|
|
116
112
|
# @see the `==` method
|
|
@@ -122,7 +118,7 @@ module Tremendous
|
|
|
122
118
|
# Calculates hash code according to all attributes.
|
|
123
119
|
# @return [Integer] Hash code
|
|
124
120
|
def hash
|
|
125
|
-
[
|
|
121
|
+
[role].hash
|
|
126
122
|
end
|
|
127
123
|
|
|
128
124
|
# Builds the object from hash
|