ultracart_api 3.10.80 → 3.10.82

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,202 @@
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 ConversationSearchResponse
17
+ attr_accessor :range_begin
18
+
19
+ attr_accessor :range_end
20
+
21
+ attr_accessor :total
22
+
23
+ # Attribute mapping from ruby-style variable name to JSON key.
24
+ def self.attribute_map
25
+ {
26
+ :'range_begin' => :'range_begin',
27
+ :'range_end' => :'range_end',
28
+ :'total' => :'total'
29
+ }
30
+ end
31
+
32
+ # Attribute type mapping.
33
+ def self.swagger_types
34
+ {
35
+ :'range_begin' => :'Integer',
36
+ :'range_end' => :'Integer',
37
+ :'total' => :'Integer'
38
+ }
39
+ end
40
+
41
+ # Initializes the object
42
+ # @param [Hash] attributes Model attributes in the form of hash
43
+ def initialize(attributes = {})
44
+ return unless attributes.is_a?(Hash)
45
+
46
+ # convert string to symbol for hash key
47
+ attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
48
+
49
+ if attributes.has_key?(:'range_begin')
50
+ self.range_begin = attributes[:'range_begin']
51
+ end
52
+
53
+ if attributes.has_key?(:'range_end')
54
+ self.range_end = attributes[:'range_end']
55
+ end
56
+
57
+ if attributes.has_key?(:'total')
58
+ self.total = attributes[:'total']
59
+ end
60
+ end
61
+
62
+ # Show invalid properties with the reasons. Usually used together with valid?
63
+ # @return Array for valid properties with the reasons
64
+ def list_invalid_properties
65
+ invalid_properties = Array.new
66
+ invalid_properties
67
+ end
68
+
69
+ # Check to see if the all the properties in the model are valid
70
+ # @return true if the model is valid
71
+ def valid?
72
+ true
73
+ end
74
+
75
+ # Checks equality by comparing each attribute.
76
+ # @param [Object] Object to be compared
77
+ def ==(o)
78
+ return true if self.equal?(o)
79
+ self.class == o.class &&
80
+ range_begin == o.range_begin &&
81
+ range_end == o.range_end &&
82
+ total == o.total
83
+ end
84
+
85
+ # @see the `==` method
86
+ # @param [Object] Object to be compared
87
+ def eql?(o)
88
+ self == o
89
+ end
90
+
91
+ # Calculates hash code according to all attributes.
92
+ # @return [Fixnum] Hash code
93
+ def hash
94
+ [range_begin, range_end, total].hash
95
+ end
96
+
97
+ # Builds the object from hash
98
+ # @param [Hash] attributes Model attributes in the form of hash
99
+ # @return [Object] Returns the model itself
100
+ def build_from_hash(attributes)
101
+ return nil unless attributes.is_a?(Hash)
102
+ self.class.swagger_types.each_pair do |key, type|
103
+ if type =~ /\AArray<(.*)>/i
104
+ # check to ensure the input is an array given that the attribute
105
+ # is documented as an array but the input is not
106
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
107
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
108
+ end
109
+ elsif !attributes[self.class.attribute_map[key]].nil?
110
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
111
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
112
+ end
113
+
114
+ self
115
+ end
116
+
117
+ # Deserializes the data based on type
118
+ # @param string type Data type
119
+ # @param string value Value to be deserialized
120
+ # @return [Object] Deserialized data
121
+ def _deserialize(type, value)
122
+ case type.to_sym
123
+ when :DateTime
124
+ DateTime.parse(value)
125
+ when :Date
126
+ Date.parse(value)
127
+ when :String
128
+ value.to_s
129
+ when :Integer
130
+ value.to_i
131
+ when :Float
132
+ value.to_f
133
+ when :BOOLEAN
134
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
135
+ true
136
+ else
137
+ false
138
+ end
139
+ when :Object
140
+ # generic object (usually a Hash), return directly
141
+ value
142
+ when /\AArray<(?<inner_type>.+)>\z/
143
+ inner_type = Regexp.last_match[:inner_type]
144
+ value.map { |v| _deserialize(inner_type, v) }
145
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
146
+ k_type = Regexp.last_match[:k_type]
147
+ v_type = Regexp.last_match[:v_type]
148
+ {}.tap do |hash|
149
+ value.each do |k, v|
150
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
151
+ end
152
+ end
153
+ else # model
154
+ temp_model = UltracartClient.const_get(type).new
155
+ temp_model.build_from_hash(value)
156
+ end
157
+ end
158
+
159
+ # Returns the string representation of the object
160
+ # @return [String] String presentation of the object
161
+ def to_s
162
+ to_hash.to_s
163
+ end
164
+
165
+ # to_body is an alias to to_hash (backward compatibility)
166
+ # @return [Hash] Returns the object in the form of hash
167
+ def to_body
168
+ to_hash
169
+ end
170
+
171
+ # Returns the object in the form of hash
172
+ # @return [Hash] Returns the object in the form of hash
173
+ def to_hash
174
+ hash = {}
175
+ self.class.attribute_map.each_pair do |attr, param|
176
+ value = self.send(attr)
177
+ next if value.nil?
178
+ hash[param] = _to_hash(value)
179
+ end
180
+ hash
181
+ end
182
+
183
+ # Outputs non-array value in the form of hash
184
+ # For object, use to_hash. Otherwise, just return the value
185
+ # @param [Object] value Any valid value
186
+ # @return [Hash] Returns the value in the form of hash
187
+ def _to_hash(value)
188
+ if value.is_a?(Array)
189
+ value.compact.map { |v| _to_hash(v) }
190
+ elsif value.is_a?(Hash)
191
+ {}.tap do |hash|
192
+ value.each { |k, v| hash[k] = _to_hash(v) }
193
+ end
194
+ elsif value.respond_to? :to_hash
195
+ value.to_hash
196
+ else
197
+ value
198
+ end
199
+ end
200
+
201
+ end
202
+ end
@@ -11,5 +11,5 @@ Swagger Codegen version: 2.4.15-SNAPSHOT
11
11
  =end
12
12
 
13
13
  module UltracartClient
14
- VERSION = '3.10.80'
14
+ VERSION = '3.10.82'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -138,6 +138,9 @@ require 'ultracart_api/models/city_state_zip'
138
138
  require 'ultracart_api/models/conversation'
139
139
  require 'ultracart_api/models/conversation_agent_auth'
140
140
  require 'ultracart_api/models/conversation_agent_auth_response'
141
+ require 'ultracart_api/models/conversation_autocomplete_request'
142
+ require 'ultracart_api/models/conversation_autocomplete_response'
143
+ require 'ultracart_api/models/conversation_autocomplete_value'
141
144
  require 'ultracart_api/models/conversation_canned_message'
142
145
  require 'ultracart_api/models/conversation_canned_message_response'
143
146
  require 'ultracart_api/models/conversation_canned_messages_response'
@@ -166,6 +169,8 @@ require 'ultracart_api/models/conversation_multimedia_upload_url'
166
169
  require 'ultracart_api/models/conversation_multimedia_upload_url_response'
167
170
  require 'ultracart_api/models/conversation_participant'
168
171
  require 'ultracart_api/models/conversation_response'
172
+ require 'ultracart_api/models/conversation_search_request'
173
+ require 'ultracart_api/models/conversation_search_response'
169
174
  require 'ultracart_api/models/conversation_start_request'
170
175
  require 'ultracart_api/models/conversation_start_response'
171
176
  require 'ultracart_api/models/conversation_summary'
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.80
4
+ version: 3.10.82
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-12-13 00:00:00.000000000 Z
11
+ date: 2022-12-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -348,6 +348,9 @@ files:
348
348
  - docs/ConversationAgentAuth.md
349
349
  - docs/ConversationAgentAuthResponse.md
350
350
  - docs/ConversationApi.md
351
+ - docs/ConversationAutocompleteRequest.md
352
+ - docs/ConversationAutocompleteResponse.md
353
+ - docs/ConversationAutocompleteValue.md
351
354
  - docs/ConversationCannedMessage.md
352
355
  - docs/ConversationCannedMessageResponse.md
353
356
  - docs/ConversationCannedMessagesResponse.md
@@ -376,6 +379,8 @@ files:
376
379
  - docs/ConversationMultimediaUploadUrlResponse.md
377
380
  - docs/ConversationParticipant.md
378
381
  - docs/ConversationResponse.md
382
+ - docs/ConversationSearchRequest.md
383
+ - docs/ConversationSearchResponse.md
379
384
  - docs/ConversationStartRequest.md
380
385
  - docs/ConversationStartResponse.md
381
386
  - docs/ConversationSummary.md
@@ -1092,6 +1097,9 @@ files:
1092
1097
  - lib/ultracart_api/models/conversation.rb
1093
1098
  - lib/ultracart_api/models/conversation_agent_auth.rb
1094
1099
  - lib/ultracart_api/models/conversation_agent_auth_response.rb
1100
+ - lib/ultracart_api/models/conversation_autocomplete_request.rb
1101
+ - lib/ultracart_api/models/conversation_autocomplete_response.rb
1102
+ - lib/ultracart_api/models/conversation_autocomplete_value.rb
1095
1103
  - lib/ultracart_api/models/conversation_canned_message.rb
1096
1104
  - lib/ultracart_api/models/conversation_canned_message_response.rb
1097
1105
  - lib/ultracart_api/models/conversation_canned_messages_response.rb
@@ -1120,6 +1128,8 @@ files:
1120
1128
  - lib/ultracart_api/models/conversation_multimedia_upload_url_response.rb
1121
1129
  - lib/ultracart_api/models/conversation_participant.rb
1122
1130
  - lib/ultracart_api/models/conversation_response.rb
1131
+ - lib/ultracart_api/models/conversation_search_request.rb
1132
+ - lib/ultracart_api/models/conversation_search_response.rb
1123
1133
  - lib/ultracart_api/models/conversation_start_request.rb
1124
1134
  - lib/ultracart_api/models/conversation_start_response.rb
1125
1135
  - lib/ultracart_api/models/conversation_summary.rb