ultracart_api 3.6.0 → 3.6.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: aaa7a1b2bde05f09562e671fa2d7e7fec6b786162407c2738d6ee4a1a38b9628
4
- data.tar.gz: d45b6adeeb52433c9cae1b741dc910acadfada6d41e5a86eb9f6fdc48051f9c4
3
+ metadata.gz: 866027b01c86dc77f25753ef62940423da3d4c300d4e05257373f7518637e180
4
+ data.tar.gz: 4d334e6f9da34ff38320f7c46fd0aa071e92ff1c38aec8c8f7ac33d560fd67b6
5
5
  SHA512:
6
- metadata.gz: 48e75b409260fa0dbfcb56cbb035e21d81e3f29b8cdb1a14ca0a7495696eed453b6034fbdcdd1b63a73e61d183a15dc03c53dd3e0ea17b35d490754f29379434
7
- data.tar.gz: a0bfbc7b51782e9a8247e9f30e2df7eef930403ba48c536c27618604308e3c8e621464b9799875d63f562600c9db3a57f745bee388145c5515815c63810ed760
6
+ metadata.gz: dc59f71d88f5deace6e67349bcd795e6daefec3702d4cee62beb3b3612572c6da74a9a7d4853c73ba0741375d32b954bcf43bfca94dda9d9ecb4505a9cc24143
7
+ data.tar.gz: 50739b1380126d0768b64dd6abe291b264e4118b59a53e5ea672cf366c78068c2ce274b8c652942a368186d4f7fcdf3592dd764a1cc49d4300b59085443ca502
data/README.md CHANGED
@@ -7,7 +7,7 @@ UltraCart REST API Version 2
7
7
  This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
8
8
 
9
9
  - API version: 2.0.0
10
- - Package version: 3.6.0
10
+ - Package version: 3.6.5
11
11
  - Build package: io.swagger.codegen.languages.RubyClientCodegen
12
12
  For more information, please visit [http://www.ultracart.com](http://www.ultracart.com)
13
13
 
@@ -24,15 +24,15 @@ gem build ultracart_api.gemspec
24
24
  Then either install the gem locally:
25
25
 
26
26
  ```shell
27
- gem install ./ultracart_api-3.6.0.gem
27
+ gem install ./ultracart_api-3.6.5.gem
28
28
  ```
29
- (for development, run `gem install --dev ./ultracart_api-3.6.0.gem` to install the development dependencies)
29
+ (for development, run `gem install --dev ./ultracart_api-3.6.5.gem` to install the development dependencies)
30
30
 
31
31
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
32
32
 
33
33
  Finally add this to the Gemfile:
34
34
 
35
- gem 'ultracart_api', '~> 3.6.0'
35
+ gem 'ultracart_api', '~> 3.6.5'
36
36
 
37
37
  ### Install from Git
38
38
 
@@ -874,6 +874,7 @@ Class | Method | HTTP request | Description
874
874
  - [UltracartClient::OrderPaymentCheck](docs/OrderPaymentCheck.md)
875
875
  - [UltracartClient::OrderPaymentCreditCard](docs/OrderPaymentCreditCard.md)
876
876
  - [UltracartClient::OrderPaymentECheck](docs/OrderPaymentECheck.md)
877
+ - [UltracartClient::OrderPaymentInsurance](docs/OrderPaymentInsurance.md)
877
878
  - [UltracartClient::OrderPaymentPurchaseOrder](docs/OrderPaymentPurchaseOrder.md)
878
879
  - [UltracartClient::OrderPaymentTransaction](docs/OrderPaymentTransaction.md)
879
880
  - [UltracartClient::OrderPaymentTransactionDetail](docs/OrderPaymentTransactionDetail.md)
@@ -905,6 +906,7 @@ Class | Method | HTTP request | Description
905
906
  - [UltracartClient::PaymentsConfigurationCreditCard](docs/PaymentsConfigurationCreditCard.md)
906
907
  - [UltracartClient::PaymentsConfigurationCreditCardType](docs/PaymentsConfigurationCreditCardType.md)
907
908
  - [UltracartClient::PaymentsConfigurationEcheck](docs/PaymentsConfigurationEcheck.md)
909
+ - [UltracartClient::PaymentsConfigurationInsurance](docs/PaymentsConfigurationInsurance.md)
908
910
  - [UltracartClient::PaymentsConfigurationLoanHero](docs/PaymentsConfigurationLoanHero.md)
909
911
  - [UltracartClient::PaymentsConfigurationMoneyOrder](docs/PaymentsConfigurationMoneyOrder.md)
910
912
  - [UltracartClient::PaymentsConfigurationPayPal](docs/PaymentsConfigurationPayPal.md)
@@ -1116,6 +1118,9 @@ Not every change is committed to every SDK.
1116
1118
 
1117
1119
  | Version | Date | Comments |
1118
1120
  | --: | :-: | --- |
1121
+ | 3.6.5 | 08/25/2021 | configuration api - removed some internal fields from sdk |
1122
+ | 3.6.4 | 08/24/2021 | configuration api - new payment method named insurance |
1123
+ | 3.6.1 | 08/23/2021 | configuration api - enum problems, also added order.item.tracking_number to support line item tracking numbers |
1119
1124
  | 3.6.0 | 08/19/2021 | coupon api - changed tieredAmountOffItem to support mulitple items |
1120
1125
  | 3.5.3 | 08/18/2021 | configuration api - added credit card rate to UltraCart Payments object |
1121
1126
  | 3.5.1 | 08/11/2021 | email webhook test method |
data/docs/OrderItem.md CHANGED
@@ -52,6 +52,7 @@ Name | Type | Description | Notes
52
52
  **taxable_cost** | [**Currency**](Currency.md) | | [optional]
53
53
  **total_cost_with_discount** | [**Currency**](Currency.md) | | [optional]
54
54
  **total_refunded** | [**Currency**](Currency.md) | | [optional]
55
+ **tracking_number** | **String** | Tracking number, if null or missing, use order level tracking number(s). Used if there are multiple shipments for one order | [optional]
55
56
  **transmitted_to_distribution_center_dts** | **String** | Date/time that this item was transmitted to the distribution center | [optional]
56
57
  **unit_cost_with_discount** | [**Currency**](Currency.md) | | [optional]
57
58
  **upsell** | **BOOLEAN** | True if this item was added to the order as part of an upsell | [optional]
data/docs/OrderPayment.md CHANGED
@@ -7,6 +7,7 @@ Name | Type | Description | Notes
7
7
  **credit_card** | [**OrderPaymentCreditCard**](OrderPaymentCreditCard.md) | | [optional]
8
8
  **echeck** | [**OrderPaymentECheck**](OrderPaymentECheck.md) | | [optional]
9
9
  **hold_for_fraud_review** | **BOOLEAN** | True if order has been held for fraud review | [optional]
10
+ **insurance** | [**OrderPaymentInsurance**](OrderPaymentInsurance.md) | | [optional]
10
11
  **payment_dts** | **String** | Date/time that the payment was successfully processed, for new orders, this field is only considered if channel_partner.skip_payment_processing is true | [optional]
11
12
  **payment_method** | **String** | Payment method | [optional]
12
13
  **payment_method_accounting_code** | **String** | Payment method QuickBooks code | [optional]
@@ -0,0 +1,9 @@
1
+ # UltracartClient::OrderPaymentInsurance
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **application_id** | **String** | application id | [optional]
7
+ **claim_id** | **String** | claim id | [optional]
8
+
9
+
@@ -10,6 +10,7 @@ Name | Type | Description | Notes
10
10
  **cod** | [**PaymentsConfigurationCOD**](PaymentsConfigurationCOD.md) | | [optional]
11
11
  **credit_card** | [**PaymentsConfigurationCreditCard**](PaymentsConfigurationCreditCard.md) | | [optional]
12
12
  **echeck** | [**PaymentsConfigurationEcheck**](PaymentsConfigurationEcheck.md) | | [optional]
13
+ **insurance** | [**PaymentsConfigurationInsurance**](PaymentsConfigurationInsurance.md) | | [optional]
13
14
  **loan_hero** | [**PaymentsConfigurationLoanHero**](PaymentsConfigurationLoanHero.md) | | [optional]
14
15
  **money_order** | [**PaymentsConfigurationMoneyOrder**](PaymentsConfigurationMoneyOrder.md) | | [optional]
15
16
  **paypal** | [**PaymentsConfigurationPayPal**](PaymentsConfigurationPayPal.md) | | [optional]
@@ -17,8 +18,6 @@ Name | Type | Description | Notes
17
18
  **quote_request** | [**PaymentsConfigurationQuoteRequest**](PaymentsConfigurationQuoteRequest.md) | | [optional]
18
19
  **sezzle** | [**PaymentsConfigurationSezzle**](PaymentsConfigurationSezzle.md) | | [optional]
19
20
  **show_accounting_code** | **BOOLEAN** | Internal flag used to determine if accounting codes should be shown on the screen or not. This flag is true if the merchant has a Quickbooks integration configured. | [optional]
20
- **switch_to_sub_tab** | **String** | | [optional]
21
- **switch_to_tab** | **String** | | [optional]
22
21
  **ultracart_payments_wepay** | [**PaymentsConfigurationWePay**](PaymentsConfigurationWePay.md) | | [optional]
23
22
  **wire_transfer** | [**PaymentsConfigurationWireTransfer**](PaymentsConfigurationWireTransfer.md) | | [optional]
24
23
 
@@ -0,0 +1,9 @@
1
+ # UltracartClient::PaymentsConfigurationInsurance
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **accept_insurance** | **BOOLEAN** | Master flag indicating this merchant accepts insurance | [optional]
7
+ **restrictions** | [**PaymentsConfigurationRestrictions**](PaymentsConfigurationRestrictions.md) | | [optional]
8
+
9
+
@@ -23,7 +23,6 @@ Name | Type | Description | Notes
23
23
  **owner_name** | **String** | Owner name | [optional]
24
24
  **owner_phone** | **String** | Owner phone | [optional]
25
25
  **postal_code** | **String** | Postal code | [optional]
26
- **remove_pay_pal_pro** | **BOOLEAN** | | [optional]
27
26
  **restrictions** | [**PaymentsConfigurationRestrictions**](PaymentsConfigurationRestrictions.md) | | [optional]
28
27
  **short_paypal_marketing_text** | **BOOLEAN** | Internal UI aid | [optional]
29
28
  **show_ultracart_payments_disabled** | **BOOLEAN** | Internal flag to aid UI | [optional]
@@ -6,18 +6,25 @@ Name | Type | Description | Notes
6
6
  **affiliate_email** | **String** | | [optional]
7
7
  **affiliate_id** | **Integer** | | [optional]
8
8
  **communications_campaign_name** | **String** | | [optional]
9
+ **communications_campaign_name_filter** | **BOOLEAN** | | [optional]
9
10
  **communications_email_subject** | **String** | | [optional]
11
+ **communications_email_subject_filter** | **BOOLEAN** | | [optional]
10
12
  **communications_flow_name** | **String** | | [optional]
13
+ **communications_flow_name_filter** | **BOOLEAN** | | [optional]
11
14
  **email** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
12
15
  **email_domain** | **String** | | [optional]
16
+ **email_domain_filter** | **BOOLEAN** | | [optional]
13
17
  **email_identified** | **BOOLEAN** | | [optional]
14
18
  **end_timestamp** | [**ScreenRecordingFilterRangeDate**](ScreenRecordingFilterRangeDate.md) | | [optional]
15
19
  **esp_customer_uuid** | **String** | | [optional]
16
20
  **favorite** | **BOOLEAN** | | [optional]
17
21
  **geolocation** | [**ScreenRecordingFilterGeoDistance**](ScreenRecordingFilterGeoDistance.md) | | [optional]
18
22
  **geolocation_country** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
23
+ **geolocation_country_filter** | **BOOLEAN** | | [optional]
19
24
  **geolocation_state** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
25
+ **geolocation_state_filter** | **BOOLEAN** | | [optional]
20
26
  **language_iso_code** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
27
+ **language_iso_code_filter** | **BOOLEAN** | | [optional]
21
28
  **last_x_days** | **Integer** | | [optional]
22
29
  **max_filter_values** | **Integer** | | [optional]
23
30
  **order_id** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
@@ -25,22 +32,35 @@ Name | Type | Description | Notes
25
32
  **page_views** | [**Array<ScreenRecordingFilterPageView>**](ScreenRecordingFilterPageView.md) | | [optional]
26
33
  **placed_order** | **BOOLEAN** | | [optional]
27
34
  **preferred_language** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
35
+ **preferred_language_filter** | **BOOLEAN** | | [optional]
28
36
  **referrer_domain** | **String** | | [optional]
37
+ **referrer_domain_filter** | **BOOLEAN** | | [optional]
29
38
  **screen_recording_uuids** | **Array<String>** | | [optional]
30
39
  **screen_sizes** | **Array<String>** | | [optional]
31
40
  **skip_filter_values** | **BOOLEAN** | | [optional]
41
+ **skip_histogram** | **BOOLEAN** | | [optional]
32
42
  **skip_hits** | **BOOLEAN** | | [optional]
33
43
  **start_timestamp** | [**ScreenRecordingFilterRangeDate**](ScreenRecordingFilterRangeDate.md) | | [optional]
34
44
  **tags** | **Array<String>** | | [optional]
35
45
  **time_on_site** | [**ScreenRecordingFilterRangeInteger**](ScreenRecordingFilterRangeInteger.md) | | [optional]
46
+ **time_on_site_max_filter** | **BOOLEAN** | | [optional]
47
+ **time_on_site_min_filter** | **BOOLEAN** | | [optional]
48
+ **url_filter** | **BOOLEAN** | | [optional]
36
49
  **user_agent_device_name** | **String** | | [optional]
50
+ **user_agent_device_name_filter** | **BOOLEAN** | | [optional]
51
+ **user_agent_device_os_name_filter** | **BOOLEAN** | | [optional]
52
+ **user_agent_device_os_version_filter** | **BOOLEAN** | | [optional]
37
53
  **user_agent_name** | **String** | | [optional]
54
+ **user_agent_name_filter** | **BOOLEAN** | | [optional]
38
55
  **user_agent_original** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
56
+ **user_agent_original_filter** | **BOOLEAN** | | [optional]
39
57
  **user_agent_os_name** | **String** | | [optional]
40
58
  **user_agent_os_version** | **String** | | [optional]
41
59
  **user_ip** | [**ScreenRecordingFilterIpSearch**](ScreenRecordingFilterIpSearch.md) | | [optional]
42
60
  **utm_campaign** | **String** | | [optional]
61
+ **utm_campaign_filter** | **BOOLEAN** | | [optional]
43
62
  **utm_source** | **String** | | [optional]
63
+ **utm_source_filter** | **BOOLEAN** | | [optional]
44
64
  **visitor_number** | **Integer** | | [optional]
45
65
  **watched** | **BOOLEAN** | | [optional]
46
66
 
@@ -4,12 +4,21 @@
4
4
  Name | Type | Description | Notes
5
5
  ------------ | ------------- | ------------- | -------------
6
6
  **domain** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
7
+ **domain_filter** | **BOOLEAN** | | [optional]
8
+ **event_name_filter** | **BOOLEAN** | | [optional]
9
+ **event_param_name_filter** | **BOOLEAN** | | [optional]
10
+ **event_param_value_filter** | **BOOLEAN** | | [optional]
7
11
  **events** | [**Array<ScreenRecordingFilterPageViewEvent>**](ScreenRecordingFilterPageViewEvent.md) | | [optional]
12
+ **param_name_filter** | **BOOLEAN** | | [optional]
13
+ **param_value_filter** | **BOOLEAN** | | [optional]
8
14
  **params** | [**Array<ScreenRecordingFilterPageViewParam>**](ScreenRecordingFilterPageViewParam.md) | | [optional]
9
15
  **referrer** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
10
16
  **referrer_params** | [**Array<ScreenRecordingFilterPageViewReferrerParam>**](ScreenRecordingFilterPageViewReferrerParam.md) | | [optional]
11
17
  **referrer_raw** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
12
18
  **time_on_page** | [**ScreenRecordingFilterRangeInteger**](ScreenRecordingFilterRangeInteger.md) | | [optional]
19
+ **time_on_page_max_filter** | **BOOLEAN** | | [optional]
20
+ **time_on_page_min_filter** | **BOOLEAN** | | [optional]
13
21
  **url** | [**ScreenRecordingFilterStringSearch**](ScreenRecordingFilterStringSearch.md) | | [optional]
22
+ **url_filter** | **BOOLEAN** | | [optional]
14
23
 
15
24
 
@@ -151,6 +151,9 @@ module UltracartClient
151
151
 
152
152
  attr_accessor :total_refunded
153
153
 
154
+ # Tracking number, if null or missing, use order level tracking number(s). Used if there are multiple shipments for one order
155
+ attr_accessor :tracking_number
156
+
154
157
  # Date/time that this item was transmitted to the distribution center
155
158
  attr_accessor :transmitted_to_distribution_center_dts
156
159
 
@@ -215,6 +218,7 @@ module UltracartClient
215
218
  :'taxable_cost' => :'taxable_cost',
216
219
  :'total_cost_with_discount' => :'total_cost_with_discount',
217
220
  :'total_refunded' => :'total_refunded',
221
+ :'tracking_number' => :'tracking_number',
218
222
  :'transmitted_to_distribution_center_dts' => :'transmitted_to_distribution_center_dts',
219
223
  :'unit_cost_with_discount' => :'unit_cost_with_discount',
220
224
  :'upsell' => :'upsell',
@@ -275,6 +279,7 @@ module UltracartClient
275
279
  :'taxable_cost' => :'Currency',
276
280
  :'total_cost_with_discount' => :'Currency',
277
281
  :'total_refunded' => :'Currency',
282
+ :'tracking_number' => :'String',
278
283
  :'transmitted_to_distribution_center_dts' => :'String',
279
284
  :'unit_cost_with_discount' => :'Currency',
280
285
  :'upsell' => :'BOOLEAN',
@@ -495,6 +500,10 @@ module UltracartClient
495
500
  self.total_refunded = attributes[:'total_refunded']
496
501
  end
497
502
 
503
+ if attributes.has_key?(:'tracking_number')
504
+ self.tracking_number = attributes[:'tracking_number']
505
+ end
506
+
498
507
  if attributes.has_key?(:'transmitted_to_distribution_center_dts')
499
508
  self.transmitted_to_distribution_center_dts = attributes[:'transmitted_to_distribution_center_dts']
500
509
  end
@@ -673,6 +682,7 @@ module UltracartClient
673
682
  taxable_cost == o.taxable_cost &&
674
683
  total_cost_with_discount == o.total_cost_with_discount &&
675
684
  total_refunded == o.total_refunded &&
685
+ tracking_number == o.tracking_number &&
676
686
  transmitted_to_distribution_center_dts == o.transmitted_to_distribution_center_dts &&
677
687
  unit_cost_with_discount == o.unit_cost_with_discount &&
678
688
  upsell == o.upsell &&
@@ -689,7 +699,7 @@ module UltracartClient
689
699
  # Calculates hash code according to all attributes.
690
700
  # @return [Fixnum] Hash code
691
701
  def hash
692
- [accounting_code, activation_codes, arbitrary_unit_cost, auto_order_last_rebill_dts, auto_order_schedule, barcode, channel_partner_item_id, cogs, component_unit_value, cost, country_code_of_origin, customs_description, description, discount, discount_quantity, discount_shipping_weight, distribution_center_code, edi, exclude_coupon, free_shipping, hazmat, height, item_reference_oid, kit, kit_component, length, manufacturer_sku, max_days_time_in_transit, merchant_item_id, mix_and_match_group_name, mix_and_match_group_oid, no_shipping_discount, options, packed_by_user, perishable_class, pricing_tier_name, properties, quantity, quantity_refunded, quickbooks_class, ship_separately, shipped_by_user, shipped_dts, special_product_type, tags, tax_free, taxable_cost, total_cost_with_discount, total_refunded, transmitted_to_distribution_center_dts, unit_cost_with_discount, upsell, weight, width].hash
702
+ [accounting_code, activation_codes, arbitrary_unit_cost, auto_order_last_rebill_dts, auto_order_schedule, barcode, channel_partner_item_id, cogs, component_unit_value, cost, country_code_of_origin, customs_description, description, discount, discount_quantity, discount_shipping_weight, distribution_center_code, edi, exclude_coupon, free_shipping, hazmat, height, item_reference_oid, kit, kit_component, length, manufacturer_sku, max_days_time_in_transit, merchant_item_id, mix_and_match_group_name, mix_and_match_group_oid, no_shipping_discount, options, packed_by_user, perishable_class, pricing_tier_name, properties, quantity, quantity_refunded, quickbooks_class, ship_separately, shipped_by_user, shipped_dts, special_product_type, tags, tax_free, taxable_cost, total_cost_with_discount, total_refunded, tracking_number, transmitted_to_distribution_center_dts, unit_cost_with_discount, upsell, weight, width].hash
693
703
  end
694
704
 
695
705
  # Builds the object from hash
@@ -23,6 +23,8 @@ module UltracartClient
23
23
  # True if order has been held for fraud review
24
24
  attr_accessor :hold_for_fraud_review
25
25
 
26
+ attr_accessor :insurance
27
+
26
28
  # Date/time that the payment was successfully processed, for new orders, this field is only considered if channel_partner.skip_payment_processing is true
27
29
  attr_accessor :payment_dts
28
30
 
@@ -89,6 +91,7 @@ module UltracartClient
89
91
  :'credit_card' => :'credit_card',
90
92
  :'echeck' => :'echeck',
91
93
  :'hold_for_fraud_review' => :'hold_for_fraud_review',
94
+ :'insurance' => :'insurance',
92
95
  :'payment_dts' => :'payment_dts',
93
96
  :'payment_method' => :'payment_method',
94
97
  :'payment_method_accounting_code' => :'payment_method_accounting_code',
@@ -112,6 +115,7 @@ module UltracartClient
112
115
  :'credit_card' => :'OrderPaymentCreditCard',
113
116
  :'echeck' => :'OrderPaymentECheck',
114
117
  :'hold_for_fraud_review' => :'BOOLEAN',
118
+ :'insurance' => :'OrderPaymentInsurance',
115
119
  :'payment_dts' => :'String',
116
120
  :'payment_method' => :'String',
117
121
  :'payment_method_accounting_code' => :'String',
@@ -152,6 +156,10 @@ module UltracartClient
152
156
  self.hold_for_fraud_review = attributes[:'hold_for_fraud_review']
153
157
  end
154
158
 
159
+ if attributes.has_key?(:'insurance')
160
+ self.insurance = attributes[:'insurance']
161
+ end
162
+
155
163
  if attributes.has_key?(:'payment_dts')
156
164
  self.payment_dts = attributes[:'payment_dts']
157
165
  end
@@ -217,7 +225,7 @@ module UltracartClient
217
225
  # Check to see if the all the properties in the model are valid
218
226
  # @return true if the model is valid
219
227
  def valid?
220
- payment_method_validator = EnumAttributeValidator.new('String', ['Affirm', 'Amazon', 'Amazon SC', 'Cash', 'Check', 'COD', 'Credit Card', 'eBay', 'eCheck', 'LoanHero', 'Money Order', 'PayPal', 'Purchase Order', 'Quote Request', 'Unknown', 'Wire Transfer', 'Walmart'])
228
+ payment_method_validator = EnumAttributeValidator.new('String', ['Affirm', 'Amazon', 'Amazon SC', 'Cash', 'Check', 'COD', 'Credit Card', 'eBay', 'eCheck', 'Insurance', 'LoanHero', 'Money Order', 'PayPal', 'Purchase Order', 'Quote Request', 'Unknown', 'Wire Transfer', 'Walmart'])
221
229
  return false unless payment_method_validator.valid?(@payment_method)
222
230
  payment_status_validator = EnumAttributeValidator.new('String', ['Unprocessed', 'Authorized', 'Capture Failed', 'Processed', 'Declined', 'Voided', 'Refunded', 'Skipped'])
223
231
  return false unless payment_status_validator.valid?(@payment_status)
@@ -227,7 +235,7 @@ module UltracartClient
227
235
  # Custom attribute writer method checking allowed values (enum).
228
236
  # @param [Object] payment_method Object to be assigned
229
237
  def payment_method=(payment_method)
230
- validator = EnumAttributeValidator.new('String', ['Affirm', 'Amazon', 'Amazon SC', 'Cash', 'Check', 'COD', 'Credit Card', 'eBay', 'eCheck', 'LoanHero', 'Money Order', 'PayPal', 'Purchase Order', 'Quote Request', 'Unknown', 'Wire Transfer', 'Walmart'])
238
+ validator = EnumAttributeValidator.new('String', ['Affirm', 'Amazon', 'Amazon SC', 'Cash', 'Check', 'COD', 'Credit Card', 'eBay', 'eCheck', 'Insurance', 'LoanHero', 'Money Order', 'PayPal', 'Purchase Order', 'Quote Request', 'Unknown', 'Wire Transfer', 'Walmart'])
231
239
  unless validator.valid?(payment_method)
232
240
  fail ArgumentError, 'invalid value for "payment_method", must be one of #{validator.allowable_values}.'
233
241
  end
@@ -253,6 +261,7 @@ module UltracartClient
253
261
  credit_card == o.credit_card &&
254
262
  echeck == o.echeck &&
255
263
  hold_for_fraud_review == o.hold_for_fraud_review &&
264
+ insurance == o.insurance &&
256
265
  payment_dts == o.payment_dts &&
257
266
  payment_method == o.payment_method &&
258
267
  payment_method_accounting_code == o.payment_method_accounting_code &&
@@ -277,7 +286,7 @@ module UltracartClient
277
286
  # Calculates hash code according to all attributes.
278
287
  # @return [Fixnum] Hash code
279
288
  def hash
280
- [check, credit_card, echeck, hold_for_fraud_review, payment_dts, payment_method, payment_method_accounting_code, payment_method_deposit_to_account, payment_status, purchase_order, rotating_transaction_gateway_code, surcharge, surcharge_accounting_code, surcharge_transaction_fee, surcharge_transaction_percentage, test_order, transactions].hash
289
+ [check, credit_card, echeck, hold_for_fraud_review, insurance, payment_dts, payment_method, payment_method_accounting_code, payment_method_deposit_to_account, payment_status, purchase_order, rotating_transaction_gateway_code, surcharge, surcharge_accounting_code, surcharge_transaction_fee, surcharge_transaction_percentage, test_order, transactions].hash
281
290
  end
282
291
 
283
292
  # Builds the object from hash
@@ -0,0 +1,195 @@
1
+ =begin
2
+ #UltraCart Rest API V2
3
+
4
+ #UltraCart REST API Version 2
5
+
6
+ OpenAPI spec version: 2.0.0
7
+ Contact: support@ultracart.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.4.15-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module UltracartClient
16
+ class OrderPaymentInsurance
17
+ # application id
18
+ attr_accessor :application_id
19
+
20
+ # claim id
21
+ attr_accessor :claim_id
22
+
23
+ # Attribute mapping from ruby-style variable name to JSON key.
24
+ def self.attribute_map
25
+ {
26
+ :'application_id' => :'application_id',
27
+ :'claim_id' => :'claim_id'
28
+ }
29
+ end
30
+
31
+ # Attribute type mapping.
32
+ def self.swagger_types
33
+ {
34
+ :'application_id' => :'String',
35
+ :'claim_id' => :'String'
36
+ }
37
+ end
38
+
39
+ # Initializes the object
40
+ # @param [Hash] attributes Model attributes in the form of hash
41
+ def initialize(attributes = {})
42
+ return unless attributes.is_a?(Hash)
43
+
44
+ # convert string to symbol for hash key
45
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
46
+
47
+ if attributes.has_key?(:'application_id')
48
+ self.application_id = attributes[:'application_id']
49
+ end
50
+
51
+ if attributes.has_key?(:'claim_id')
52
+ self.claim_id = attributes[:'claim_id']
53
+ end
54
+ end
55
+
56
+ # Show invalid properties with the reasons. Usually used together with valid?
57
+ # @return Array for valid properties with the reasons
58
+ def list_invalid_properties
59
+ invalid_properties = Array.new
60
+ invalid_properties
61
+ end
62
+
63
+ # Check to see if the all the properties in the model are valid
64
+ # @return true if the model is valid
65
+ def valid?
66
+ true
67
+ end
68
+
69
+ # Checks equality by comparing each attribute.
70
+ # @param [Object] Object to be compared
71
+ def ==(o)
72
+ return true if self.equal?(o)
73
+ self.class == o.class &&
74
+ application_id == o.application_id &&
75
+ claim_id == o.claim_id
76
+ end
77
+
78
+ # @see the `==` method
79
+ # @param [Object] Object to be compared
80
+ def eql?(o)
81
+ self == o
82
+ end
83
+
84
+ # Calculates hash code according to all attributes.
85
+ # @return [Fixnum] Hash code
86
+ def hash
87
+ [application_id, claim_id].hash
88
+ end
89
+
90
+ # Builds the object from hash
91
+ # @param [Hash] attributes Model attributes in the form of hash
92
+ # @return [Object] Returns the model itself
93
+ def build_from_hash(attributes)
94
+ return nil unless attributes.is_a?(Hash)
95
+ self.class.swagger_types.each_pair do |key, type|
96
+ if type =~ /\AArray<(.*)>/i
97
+ # check to ensure the input is an array given that the attribute
98
+ # is documented as an array but the input is not
99
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
100
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
101
+ end
102
+ elsif !attributes[self.class.attribute_map[key]].nil?
103
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
104
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
105
+ end
106
+
107
+ self
108
+ end
109
+
110
+ # Deserializes the data based on type
111
+ # @param string type Data type
112
+ # @param string value Value to be deserialized
113
+ # @return [Object] Deserialized data
114
+ def _deserialize(type, value)
115
+ case type.to_sym
116
+ when :DateTime
117
+ DateTime.parse(value)
118
+ when :Date
119
+ Date.parse(value)
120
+ when :String
121
+ value.to_s
122
+ when :Integer
123
+ value.to_i
124
+ when :Float
125
+ value.to_f
126
+ when :BOOLEAN
127
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
128
+ true
129
+ else
130
+ false
131
+ end
132
+ when :Object
133
+ # generic object (usually a Hash), return directly
134
+ value
135
+ when /\AArray<(?<inner_type>.+)>\z/
136
+ inner_type = Regexp.last_match[:inner_type]
137
+ value.map { |v| _deserialize(inner_type, v) }
138
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
139
+ k_type = Regexp.last_match[:k_type]
140
+ v_type = Regexp.last_match[:v_type]
141
+ {}.tap do |hash|
142
+ value.each do |k, v|
143
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
144
+ end
145
+ end
146
+ else # model
147
+ temp_model = UltracartClient.const_get(type).new
148
+ temp_model.build_from_hash(value)
149
+ end
150
+ end
151
+
152
+ # Returns the string representation of the object
153
+ # @return [String] String presentation of the object
154
+ def to_s
155
+ to_hash.to_s
156
+ end
157
+
158
+ # to_body is an alias to to_hash (backward compatibility)
159
+ # @return [Hash] Returns the object in the form of hash
160
+ def to_body
161
+ to_hash
162
+ end
163
+
164
+ # Returns the object in the form of hash
165
+ # @return [Hash] Returns the object in the form of hash
166
+ def to_hash
167
+ hash = {}
168
+ self.class.attribute_map.each_pair do |attr, param|
169
+ value = self.send(attr)
170
+ next if value.nil?
171
+ hash[param] = _to_hash(value)
172
+ end
173
+ hash
174
+ end
175
+
176
+ # Outputs non-array value in the form of hash
177
+ # For object, use to_hash. Otherwise, just return the value
178
+ # @param [Object] value Any valid value
179
+ # @return [Hash] Returns the value in the form of hash
180
+ def _to_hash(value)
181
+ if value.is_a?(Array)
182
+ value.compact.map { |v| _to_hash(v) }
183
+ elsif value.is_a?(Hash)
184
+ {}.tap do |hash|
185
+ value.each { |k, v| hash[k] = _to_hash(v) }
186
+ end
187
+ elsif value.respond_to? :to_hash
188
+ value.to_hash
189
+ else
190
+ value
191
+ end
192
+ end
193
+
194
+ end
195
+ end