ultracart_api 3.10.43 → 3.10.44
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/README.md +8 -4
- data/docs/RulerValidationRequest.md +8 -0
- data/docs/RulerValidationResponse.md +9 -0
- data/docs/StorefrontApi.md +49 -0
- data/lib/ultracart_api/api/storefront_api.rb +53 -0
- data/lib/ultracart_api/models/ruler_validation_request.rb +184 -0
- data/lib/ultracart_api/models/ruler_validation_response.rb +193 -0
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +2 -0
- metadata +6 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4397a2c1f7dacb64747fd978b2fb1fe0909603ef26a09058eb6235f090bfb7da
|
|
4
|
+
data.tar.gz: bd9d1f4bbea6cf0092d5332f56948768450e4d766ebbaa2529926cd7b875e443
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cf5edebebe495ec0a8defc27958223108e694a117ac85328eacd4710375bd25c72196cca48832456f1081db9d8490fd8eb15ded27795e6bc8110d38417860408
|
|
7
|
+
data.tar.gz: 7c853bebddc30c3acc08a611b37e5ed2e07ba325840a5974ad34ee07144bd47c5ad551326b43ca3a7cedab71832a5f59c753eb6265640a1cd793f5db1a3aff76
|
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.10.
|
|
10
|
+
- Package version: 3.10.44
|
|
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.10.
|
|
27
|
+
gem install ./ultracart_api-3.10.44.gem
|
|
28
28
|
```
|
|
29
|
-
(for development, run `gem install --dev ./ultracart_api-3.10.
|
|
29
|
+
(for development, run `gem install --dev ./ultracart_api-3.10.44.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.10.
|
|
35
|
+
gem 'ultracart_api', '~> 3.10.44'
|
|
36
36
|
|
|
37
37
|
### Install from Git
|
|
38
38
|
|
|
@@ -393,6 +393,7 @@ Class | Method | HTTP request | Description
|
|
|
393
393
|
*UltracartClient::StorefrontApi* | [**update_screen_recording_tags**](docs/StorefrontApi.md#update_screen_recording_tags) | **POST** /storefront/{storefront_oid}/screen_recordings/{screen_recording_uuid}/tags | Update tags on a screen recording
|
|
394
394
|
*UltracartClient::StorefrontApi* | [**update_transaction_email**](docs/StorefrontApi.md#update_transaction_email) | **PUT** /storefront/{storefront_oid}/transaction_email/list/{email_id} | Updates a transaction email object
|
|
395
395
|
*UltracartClient::StorefrontApi* | [**update_twilio_account**](docs/StorefrontApi.md#update_twilio_account) | **PUT** /storefront/twilio/accounts/{esp_twilio_uuid} | Update Twilio account
|
|
396
|
+
*UltracartClient::StorefrontApi* | [**validate_ruler**](docs/StorefrontApi.md#validate_ruler) | **POST** /storefront/ruler/validate | Validate AWS Event Ruler
|
|
396
397
|
*UltracartClient::TaxApi* | [**delete_tax_provider_self_city**](docs/TaxApi.md#delete_tax_provider_self_city) | **DELETE** /tax/providers/self/city/{city} | Deletes a Self tax provider city
|
|
397
398
|
*UltracartClient::TaxApi* | [**delete_tax_provider_self_country**](docs/TaxApi.md#delete_tax_provider_self_country) | **DELETE** /tax/providers/self/country/{countryCode} | Deletes a Self tax provider country
|
|
398
399
|
*UltracartClient::TaxApi* | [**delete_tax_provider_self_county**](docs/TaxApi.md#delete_tax_provider_self_county) | **DELETE** /tax/providers/self/county/{county} | Deletes a Self tax provider county
|
|
@@ -994,6 +995,8 @@ Class | Method | HTTP request | Description
|
|
|
994
995
|
- [UltracartClient::RegisterAffiliateClickResponse](docs/RegisterAffiliateClickResponse.md)
|
|
995
996
|
- [UltracartClient::ResponseMetadata](docs/ResponseMetadata.md)
|
|
996
997
|
- [UltracartClient::ResultSet](docs/ResultSet.md)
|
|
998
|
+
- [UltracartClient::RulerValidationRequest](docs/RulerValidationRequest.md)
|
|
999
|
+
- [UltracartClient::RulerValidationResponse](docs/RulerValidationResponse.md)
|
|
997
1000
|
- [UltracartClient::ScreenRecording](docs/ScreenRecording.md)
|
|
998
1001
|
- [UltracartClient::ScreenRecordingAdPlatform](docs/ScreenRecordingAdPlatform.md)
|
|
999
1002
|
- [UltracartClient::ScreenRecordingFilter](docs/ScreenRecordingFilter.md)
|
|
@@ -1179,6 +1182,7 @@ Not every change is committed to every SDK.
|
|
|
1179
1182
|
|
|
1180
1183
|
| Version | Date | Comments |
|
|
1181
1184
|
| --: | :-: | --- |
|
|
1185
|
+
| 3.10.44 | 09/07/2022 | sf comms - using aws event ruler for bigquery segmentation validation |
|
|
1182
1186
|
| 3.10.43 | 09/02/2022 | customer editor added loyal ledger descriptions |
|
|
1183
1187
|
| 3.10.42 | 08/30/2022 | storefront comm fields for sms configuration |
|
|
1184
1188
|
| 3.10.41 | 08/26/2022 | postcard address fields for comm sequence testing |
|
data/docs/StorefrontApi.md
CHANGED
|
@@ -168,6 +168,7 @@ Method | HTTP request | Description
|
|
|
168
168
|
[**update_screen_recording_tags**](StorefrontApi.md#update_screen_recording_tags) | **POST** /storefront/{storefront_oid}/screen_recordings/{screen_recording_uuid}/tags | Update tags on a screen recording
|
|
169
169
|
[**update_transaction_email**](StorefrontApi.md#update_transaction_email) | **PUT** /storefront/{storefront_oid}/transaction_email/list/{email_id} | Updates a transaction email object
|
|
170
170
|
[**update_twilio_account**](StorefrontApi.md#update_twilio_account) | **PUT** /storefront/twilio/accounts/{esp_twilio_uuid} | Update Twilio account
|
|
171
|
+
[**validate_ruler**](StorefrontApi.md#validate_ruler) | **POST** /storefront/ruler/validate | Validate AWS Event Ruler
|
|
171
172
|
|
|
172
173
|
|
|
173
174
|
# **add_to_library**
|
|
@@ -8622,3 +8623,51 @@ Name | Type | Description | Notes
|
|
|
8622
8623
|
|
|
8623
8624
|
|
|
8624
8625
|
|
|
8626
|
+
# **validate_ruler**
|
|
8627
|
+
> RulerValidationResponse validate_ruler(ruler_validate_request)
|
|
8628
|
+
|
|
8629
|
+
Validate AWS Event Ruler
|
|
8630
|
+
|
|
8631
|
+
### Example
|
|
8632
|
+
```ruby
|
|
8633
|
+
# load the gem
|
|
8634
|
+
require 'ultracart_api'
|
|
8635
|
+
|
|
8636
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
|
8637
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
|
8638
|
+
api_instance = UltracartClient::StorefrontApi.new_using_api_key(simple_key, false, false)
|
|
8639
|
+
|
|
8640
|
+
|
|
8641
|
+
ruler_validate_request = UltracartClient::RulerValidationRequest.new # RulerValidationRequest | Ruler Validate Request
|
|
8642
|
+
|
|
8643
|
+
|
|
8644
|
+
begin
|
|
8645
|
+
#Validate AWS Event Ruler
|
|
8646
|
+
result = api_instance.validate_ruler(ruler_validate_request)
|
|
8647
|
+
p result
|
|
8648
|
+
rescue UltracartClient::ApiError => e
|
|
8649
|
+
puts "Exception when calling StorefrontApi->validate_ruler: #{e}"
|
|
8650
|
+
end
|
|
8651
|
+
```
|
|
8652
|
+
|
|
8653
|
+
### Parameters
|
|
8654
|
+
|
|
8655
|
+
Name | Type | Description | Notes
|
|
8656
|
+
------------- | ------------- | ------------- | -------------
|
|
8657
|
+
**ruler_validate_request** | [**RulerValidationRequest**](RulerValidationRequest.md)| Ruler Validate Request |
|
|
8658
|
+
|
|
8659
|
+
### Return type
|
|
8660
|
+
|
|
8661
|
+
[**RulerValidationResponse**](RulerValidationResponse.md)
|
|
8662
|
+
|
|
8663
|
+
### Authorization
|
|
8664
|
+
|
|
8665
|
+
[ultraCartBrowserApiKey](../README.md#ultraCartBrowserApiKey), [ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
|
8666
|
+
|
|
8667
|
+
### HTTP request headers
|
|
8668
|
+
|
|
8669
|
+
- **Content-Type**: application/json
|
|
8670
|
+
- **Accept**: application/json
|
|
8671
|
+
|
|
8672
|
+
|
|
8673
|
+
|
|
@@ -9725,5 +9725,58 @@ module UltracartClient
|
|
|
9725
9725
|
end
|
|
9726
9726
|
return data, status_code, headers
|
|
9727
9727
|
end
|
|
9728
|
+
# Validate AWS Event Ruler
|
|
9729
|
+
# @param ruler_validate_request Ruler Validate Request
|
|
9730
|
+
# @param [Hash] opts the optional parameters
|
|
9731
|
+
# @return [RulerValidationResponse]
|
|
9732
|
+
def validate_ruler(ruler_validate_request, opts = {})
|
|
9733
|
+
data, _status_code, _headers = validate_ruler_with_http_info(ruler_validate_request, opts)
|
|
9734
|
+
data
|
|
9735
|
+
end
|
|
9736
|
+
|
|
9737
|
+
# Validate AWS Event Ruler
|
|
9738
|
+
# @param ruler_validate_request Ruler Validate Request
|
|
9739
|
+
# @param [Hash] opts the optional parameters
|
|
9740
|
+
# @return [Array<(RulerValidationResponse, Fixnum, Hash)>] RulerValidationResponse data, response status code and response headers
|
|
9741
|
+
def validate_ruler_with_http_info(ruler_validate_request, opts = {})
|
|
9742
|
+
if @api_client.config.debugging
|
|
9743
|
+
@api_client.config.logger.debug 'Calling API: StorefrontApi.validate_ruler ...'
|
|
9744
|
+
end
|
|
9745
|
+
# verify the required parameter 'ruler_validate_request' is set
|
|
9746
|
+
if @api_client.config.client_side_validation && ruler_validate_request.nil?
|
|
9747
|
+
fail ArgumentError, "Missing the required parameter 'ruler_validate_request' when calling StorefrontApi.validate_ruler"
|
|
9748
|
+
end
|
|
9749
|
+
# resource path
|
|
9750
|
+
local_var_path = '/storefront/ruler/validate'
|
|
9751
|
+
|
|
9752
|
+
# query parameters
|
|
9753
|
+
query_params = {}
|
|
9754
|
+
|
|
9755
|
+
# header parameters
|
|
9756
|
+
header_params = {}
|
|
9757
|
+
header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
|
|
9758
|
+
# HTTP header 'Accept' (if needed)
|
|
9759
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
9760
|
+
# HTTP header 'Content-Type'
|
|
9761
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
9762
|
+
|
|
9763
|
+
# form parameters
|
|
9764
|
+
form_params = {}
|
|
9765
|
+
|
|
9766
|
+
# http body (model)
|
|
9767
|
+
post_body = @api_client.object_to_http_body(ruler_validate_request)
|
|
9768
|
+
auth_names = ['ultraCartBrowserApiKey', 'ultraCartOauth', 'ultraCartSimpleApiKey']
|
|
9769
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
|
9770
|
+
:header_params => header_params,
|
|
9771
|
+
:query_params => query_params,
|
|
9772
|
+
:form_params => form_params,
|
|
9773
|
+
:body => post_body,
|
|
9774
|
+
:auth_names => auth_names,
|
|
9775
|
+
:return_type => 'RulerValidationResponse')
|
|
9776
|
+
if @api_client.config.debugging
|
|
9777
|
+
@api_client.config.logger.debug "API called: StorefrontApi#validate_ruler\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
9778
|
+
end
|
|
9779
|
+
return data, status_code, headers
|
|
9780
|
+
end
|
|
9728
9781
|
end
|
|
9729
9782
|
end
|
|
@@ -0,0 +1,184 @@
|
|
|
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 RulerValidationRequest
|
|
17
|
+
attr_accessor :ruler
|
|
18
|
+
|
|
19
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
20
|
+
def self.attribute_map
|
|
21
|
+
{
|
|
22
|
+
:'ruler' => :'ruler'
|
|
23
|
+
}
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
# Attribute type mapping.
|
|
27
|
+
def self.swagger_types
|
|
28
|
+
{
|
|
29
|
+
:'ruler' => :'String'
|
|
30
|
+
}
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
# Initializes the object
|
|
34
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
35
|
+
def initialize(attributes = {})
|
|
36
|
+
return unless attributes.is_a?(Hash)
|
|
37
|
+
|
|
38
|
+
# convert string to symbol for hash key
|
|
39
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
|
40
|
+
|
|
41
|
+
if attributes.has_key?(:'ruler')
|
|
42
|
+
self.ruler = attributes[:'ruler']
|
|
43
|
+
end
|
|
44
|
+
end
|
|
45
|
+
|
|
46
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
47
|
+
# @return Array for valid properties with the reasons
|
|
48
|
+
def list_invalid_properties
|
|
49
|
+
invalid_properties = Array.new
|
|
50
|
+
invalid_properties
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Check to see if the all the properties in the model are valid
|
|
54
|
+
# @return true if the model is valid
|
|
55
|
+
def valid?
|
|
56
|
+
true
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
# Checks equality by comparing each attribute.
|
|
60
|
+
# @param [Object] Object to be compared
|
|
61
|
+
def ==(o)
|
|
62
|
+
return true if self.equal?(o)
|
|
63
|
+
self.class == o.class &&
|
|
64
|
+
ruler == o.ruler
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
# @see the `==` method
|
|
68
|
+
# @param [Object] Object to be compared
|
|
69
|
+
def eql?(o)
|
|
70
|
+
self == o
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# Calculates hash code according to all attributes.
|
|
74
|
+
# @return [Fixnum] Hash code
|
|
75
|
+
def hash
|
|
76
|
+
[ruler].hash
|
|
77
|
+
end
|
|
78
|
+
|
|
79
|
+
# Builds the object from hash
|
|
80
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
81
|
+
# @return [Object] Returns the model itself
|
|
82
|
+
def build_from_hash(attributes)
|
|
83
|
+
return nil unless attributes.is_a?(Hash)
|
|
84
|
+
self.class.swagger_types.each_pair do |key, type|
|
|
85
|
+
if type =~ /\AArray<(.*)>/i
|
|
86
|
+
# check to ensure the input is an array given that the attribute
|
|
87
|
+
# is documented as an array but the input is not
|
|
88
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
89
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
90
|
+
end
|
|
91
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
92
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
93
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
|
94
|
+
end
|
|
95
|
+
|
|
96
|
+
self
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
# Deserializes the data based on type
|
|
100
|
+
# @param string type Data type
|
|
101
|
+
# @param string value Value to be deserialized
|
|
102
|
+
# @return [Object] Deserialized data
|
|
103
|
+
def _deserialize(type, value)
|
|
104
|
+
case type.to_sym
|
|
105
|
+
when :DateTime
|
|
106
|
+
DateTime.parse(value)
|
|
107
|
+
when :Date
|
|
108
|
+
Date.parse(value)
|
|
109
|
+
when :String
|
|
110
|
+
value.to_s
|
|
111
|
+
when :Integer
|
|
112
|
+
value.to_i
|
|
113
|
+
when :Float
|
|
114
|
+
value.to_f
|
|
115
|
+
when :BOOLEAN
|
|
116
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
117
|
+
true
|
|
118
|
+
else
|
|
119
|
+
false
|
|
120
|
+
end
|
|
121
|
+
when :Object
|
|
122
|
+
# generic object (usually a Hash), return directly
|
|
123
|
+
value
|
|
124
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
125
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
126
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
127
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
128
|
+
k_type = Regexp.last_match[:k_type]
|
|
129
|
+
v_type = Regexp.last_match[:v_type]
|
|
130
|
+
{}.tap do |hash|
|
|
131
|
+
value.each do |k, v|
|
|
132
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
else # model
|
|
136
|
+
temp_model = UltracartClient.const_get(type).new
|
|
137
|
+
temp_model.build_from_hash(value)
|
|
138
|
+
end
|
|
139
|
+
end
|
|
140
|
+
|
|
141
|
+
# Returns the string representation of the object
|
|
142
|
+
# @return [String] String presentation of the object
|
|
143
|
+
def to_s
|
|
144
|
+
to_hash.to_s
|
|
145
|
+
end
|
|
146
|
+
|
|
147
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
148
|
+
# @return [Hash] Returns the object in the form of hash
|
|
149
|
+
def to_body
|
|
150
|
+
to_hash
|
|
151
|
+
end
|
|
152
|
+
|
|
153
|
+
# Returns the object in the form of hash
|
|
154
|
+
# @return [Hash] Returns the object in the form of hash
|
|
155
|
+
def to_hash
|
|
156
|
+
hash = {}
|
|
157
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
158
|
+
value = self.send(attr)
|
|
159
|
+
next if value.nil?
|
|
160
|
+
hash[param] = _to_hash(value)
|
|
161
|
+
end
|
|
162
|
+
hash
|
|
163
|
+
end
|
|
164
|
+
|
|
165
|
+
# Outputs non-array value in the form of hash
|
|
166
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
167
|
+
# @param [Object] value Any valid value
|
|
168
|
+
# @return [Hash] Returns the value in the form of hash
|
|
169
|
+
def _to_hash(value)
|
|
170
|
+
if value.is_a?(Array)
|
|
171
|
+
value.compact.map { |v| _to_hash(v) }
|
|
172
|
+
elsif value.is_a?(Hash)
|
|
173
|
+
{}.tap do |hash|
|
|
174
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
175
|
+
end
|
|
176
|
+
elsif value.respond_to? :to_hash
|
|
177
|
+
value.to_hash
|
|
178
|
+
else
|
|
179
|
+
value
|
|
180
|
+
end
|
|
181
|
+
end
|
|
182
|
+
|
|
183
|
+
end
|
|
184
|
+
end
|
|
@@ -0,0 +1,193 @@
|
|
|
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 RulerValidationResponse
|
|
17
|
+
attr_accessor :error_message
|
|
18
|
+
|
|
19
|
+
attr_accessor :valid
|
|
20
|
+
|
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
22
|
+
def self.attribute_map
|
|
23
|
+
{
|
|
24
|
+
:'error_message' => :'error_message',
|
|
25
|
+
:'valid' => :'valid'
|
|
26
|
+
}
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
# Attribute type mapping.
|
|
30
|
+
def self.swagger_types
|
|
31
|
+
{
|
|
32
|
+
:'error_message' => :'String',
|
|
33
|
+
:'valid' => :'BOOLEAN'
|
|
34
|
+
}
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Initializes the object
|
|
38
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
39
|
+
def initialize(attributes = {})
|
|
40
|
+
return unless attributes.is_a?(Hash)
|
|
41
|
+
|
|
42
|
+
# convert string to symbol for hash key
|
|
43
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
|
44
|
+
|
|
45
|
+
if attributes.has_key?(:'error_message')
|
|
46
|
+
self.error_message = attributes[:'error_message']
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
if attributes.has_key?(:'valid')
|
|
50
|
+
self.valid = attributes[:'valid']
|
|
51
|
+
end
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
55
|
+
# @return Array for valid properties with the reasons
|
|
56
|
+
def list_invalid_properties
|
|
57
|
+
invalid_properties = Array.new
|
|
58
|
+
invalid_properties
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# Check to see if the all the properties in the model are valid
|
|
62
|
+
# @return true if the model is valid
|
|
63
|
+
def valid?
|
|
64
|
+
true
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
# Checks equality by comparing each attribute.
|
|
68
|
+
# @param [Object] Object to be compared
|
|
69
|
+
def ==(o)
|
|
70
|
+
return true if self.equal?(o)
|
|
71
|
+
self.class == o.class &&
|
|
72
|
+
error_message == o.error_message &&
|
|
73
|
+
valid == o.valid
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
# @see the `==` method
|
|
77
|
+
# @param [Object] Object to be compared
|
|
78
|
+
def eql?(o)
|
|
79
|
+
self == o
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
# Calculates hash code according to all attributes.
|
|
83
|
+
# @return [Fixnum] Hash code
|
|
84
|
+
def hash
|
|
85
|
+
[error_message, valid].hash
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
# Builds the object from hash
|
|
89
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
90
|
+
# @return [Object] Returns the model itself
|
|
91
|
+
def build_from_hash(attributes)
|
|
92
|
+
return nil unless attributes.is_a?(Hash)
|
|
93
|
+
self.class.swagger_types.each_pair do |key, type|
|
|
94
|
+
if type =~ /\AArray<(.*)>/i
|
|
95
|
+
# check to ensure the input is an array given that the attribute
|
|
96
|
+
# is documented as an array but the input is not
|
|
97
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
98
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
99
|
+
end
|
|
100
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
101
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
102
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
|
103
|
+
end
|
|
104
|
+
|
|
105
|
+
self
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
# Deserializes the data based on type
|
|
109
|
+
# @param string type Data type
|
|
110
|
+
# @param string value Value to be deserialized
|
|
111
|
+
# @return [Object] Deserialized data
|
|
112
|
+
def _deserialize(type, value)
|
|
113
|
+
case type.to_sym
|
|
114
|
+
when :DateTime
|
|
115
|
+
DateTime.parse(value)
|
|
116
|
+
when :Date
|
|
117
|
+
Date.parse(value)
|
|
118
|
+
when :String
|
|
119
|
+
value.to_s
|
|
120
|
+
when :Integer
|
|
121
|
+
value.to_i
|
|
122
|
+
when :Float
|
|
123
|
+
value.to_f
|
|
124
|
+
when :BOOLEAN
|
|
125
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
126
|
+
true
|
|
127
|
+
else
|
|
128
|
+
false
|
|
129
|
+
end
|
|
130
|
+
when :Object
|
|
131
|
+
# generic object (usually a Hash), return directly
|
|
132
|
+
value
|
|
133
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
134
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
135
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
136
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
137
|
+
k_type = Regexp.last_match[:k_type]
|
|
138
|
+
v_type = Regexp.last_match[:v_type]
|
|
139
|
+
{}.tap do |hash|
|
|
140
|
+
value.each do |k, v|
|
|
141
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
142
|
+
end
|
|
143
|
+
end
|
|
144
|
+
else # model
|
|
145
|
+
temp_model = UltracartClient.const_get(type).new
|
|
146
|
+
temp_model.build_from_hash(value)
|
|
147
|
+
end
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
# Returns the string representation of the object
|
|
151
|
+
# @return [String] String presentation of the object
|
|
152
|
+
def to_s
|
|
153
|
+
to_hash.to_s
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
157
|
+
# @return [Hash] Returns the object in the form of hash
|
|
158
|
+
def to_body
|
|
159
|
+
to_hash
|
|
160
|
+
end
|
|
161
|
+
|
|
162
|
+
# Returns the object in the form of hash
|
|
163
|
+
# @return [Hash] Returns the object in the form of hash
|
|
164
|
+
def to_hash
|
|
165
|
+
hash = {}
|
|
166
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
167
|
+
value = self.send(attr)
|
|
168
|
+
next if value.nil?
|
|
169
|
+
hash[param] = _to_hash(value)
|
|
170
|
+
end
|
|
171
|
+
hash
|
|
172
|
+
end
|
|
173
|
+
|
|
174
|
+
# Outputs non-array value in the form of hash
|
|
175
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
176
|
+
# @param [Object] value Any valid value
|
|
177
|
+
# @return [Hash] Returns the value in the form of hash
|
|
178
|
+
def _to_hash(value)
|
|
179
|
+
if value.is_a?(Array)
|
|
180
|
+
value.compact.map { |v| _to_hash(v) }
|
|
181
|
+
elsif value.is_a?(Hash)
|
|
182
|
+
{}.tap do |hash|
|
|
183
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
184
|
+
end
|
|
185
|
+
elsif value.respond_to? :to_hash
|
|
186
|
+
value.to_hash
|
|
187
|
+
else
|
|
188
|
+
value
|
|
189
|
+
end
|
|
190
|
+
end
|
|
191
|
+
|
|
192
|
+
end
|
|
193
|
+
end
|
data/lib/ultracart_api.rb
CHANGED
|
@@ -567,6 +567,8 @@ require 'ultracart_api/models/register_affiliate_click_request'
|
|
|
567
567
|
require 'ultracart_api/models/register_affiliate_click_response'
|
|
568
568
|
require 'ultracart_api/models/response_metadata'
|
|
569
569
|
require 'ultracart_api/models/result_set'
|
|
570
|
+
require 'ultracart_api/models/ruler_validation_request'
|
|
571
|
+
require 'ultracart_api/models/ruler_validation_response'
|
|
570
572
|
require 'ultracart_api/models/screen_recording'
|
|
571
573
|
require 'ultracart_api/models/screen_recording_ad_platform'
|
|
572
574
|
require 'ultracart_api/models/screen_recording_filter'
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ultracart_api
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.10.
|
|
4
|
+
version: 3.10.44
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- UltraCart
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2022-09-
|
|
11
|
+
date: 2022-09-07 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: typhoeus
|
|
@@ -785,6 +785,8 @@ files:
|
|
|
785
785
|
- docs/RegisterAffiliateClickResponse.md
|
|
786
786
|
- docs/ResponseMetadata.md
|
|
787
787
|
- docs/ResultSet.md
|
|
788
|
+
- docs/RulerValidationRequest.md
|
|
789
|
+
- docs/RulerValidationResponse.md
|
|
788
790
|
- docs/ScreenRecording.md
|
|
789
791
|
- docs/ScreenRecordingAdPlatform.md
|
|
790
792
|
- docs/ScreenRecordingFilter.md
|
|
@@ -1479,6 +1481,8 @@ files:
|
|
|
1479
1481
|
- lib/ultracart_api/models/register_affiliate_click_response.rb
|
|
1480
1482
|
- lib/ultracart_api/models/response_metadata.rb
|
|
1481
1483
|
- lib/ultracart_api/models/result_set.rb
|
|
1484
|
+
- lib/ultracart_api/models/ruler_validation_request.rb
|
|
1485
|
+
- lib/ultracart_api/models/ruler_validation_response.rb
|
|
1482
1486
|
- lib/ultracart_api/models/screen_recording.rb
|
|
1483
1487
|
- lib/ultracart_api/models/screen_recording_ad_platform.rb
|
|
1484
1488
|
- lib/ultracart_api/models/screen_recording_filter.rb
|