ultracart_api 4.0.40.rc → 4.0.41.rc

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 76013e5a63e089f1e40ed70b618beb58c0ecfb27836590c30970a63081b50541
4
- data.tar.gz: b976780adb3bb8a80f81f0d5a73d07532edd764997e66b944488ea56c0ca6cf3
3
+ metadata.gz: 544fa63cbd77f4458b243746e53f49d5177c0e6ebd932bf8cb8c3bdaee0df1e0
4
+ data.tar.gz: f82f23fb45f963b3f58709f079fcf37091d8fc527beb479b15bbf3c8451fef75
5
5
  SHA512:
6
- metadata.gz: 19040f00897b6b9b015f78a3ae05f5894367f688cb2f1ab38c4a388edd46959c2172a494c254ef2fc5008999b523fe7f8dffe90a9fa92c8fd262529634dd536c
7
- data.tar.gz: 1c694c816b9df21260ca6b9267b81d0bf2f3b39311025ac3cf89a56212e7345bead4799eabcbc465b505f8d1e0163c13cc64dd365740f7fa57b1f2b3e19b5532
6
+ metadata.gz: fae6b9d9bae72d0fd38b4661d4de18bc2d3328dab7355ddef99f8b90af92ee8efa06153920a5693a315b06200dd112ab7028128335460303773cc23a289d9d0d
7
+ data.tar.gz: 945bad1864f47fd43a0f5559b5f2e3fb62efb6f1a6cdf5bb9129c35b6f44494e244bf9332df4a5901efbd4f21feac3d2f0e86e0a9cbe801e81f35ac18e4c49c4
data/README.md CHANGED
@@ -7,7 +7,7 @@ UltraCart REST API Version 2
7
7
  This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
8
8
 
9
9
  - API version: 2.0.0
10
- - Package version: 4.0.40.rc
10
+ - Package version: 4.0.41.rc
11
11
  - Build package: org.openapitools.codegen.languages.RubyClientCodegen
12
12
  For more information, please visit [http://www.ultracart.com](http://www.ultracart.com)
13
13
 
@@ -24,16 +24,16 @@ gem build ultracart_api.gemspec
24
24
  Then either install the gem locally:
25
25
 
26
26
  ```shell
27
- gem install ./ultracart_api-4.0.40.rc.gem
27
+ gem install ./ultracart_api-4.0.41.rc.gem
28
28
  ```
29
29
 
30
- (for development, run `gem install --dev ./ultracart_api-4.0.40.rc.gem` to install the development dependencies)
30
+ (for development, run `gem install --dev ./ultracart_api-4.0.41.rc.gem` to install the development dependencies)
31
31
 
32
32
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
33
33
 
34
34
  Finally add this to the Gemfile:
35
35
 
36
- gem 'ultracart_api', '~> 4.0.40.rc'
36
+ gem 'ultracart_api', '~> 4.0.41.rc'
37
37
 
38
38
  ### Install from Git
39
39
 
@@ -565,6 +565,7 @@ Class | Method | HTTP request | Description
565
565
  - [UltracartClient::Conversation](docs/Conversation.md)
566
566
  - [UltracartClient::ConversationAgentAuth](docs/ConversationAgentAuth.md)
567
567
  - [UltracartClient::ConversationAgentAuthResponse](docs/ConversationAgentAuthResponse.md)
568
+ - [UltracartClient::ConversationEventQueuePosition](docs/ConversationEventQueuePosition.md)
568
569
  - [UltracartClient::ConversationMessage](docs/ConversationMessage.md)
569
570
  - [UltracartClient::ConversationMessageTransportStatus](docs/ConversationMessageTransportStatus.md)
570
571
  - [UltracartClient::ConversationMultimediaUploadUrl](docs/ConversationMultimediaUploadUrl.md)
@@ -1166,6 +1167,7 @@ Not every change is committed to every SDK.
1166
1167
 
1167
1168
  | Version | Date | Comments |
1168
1169
  | --: | :-: | --- |
1170
+ | 4.0.41-RC | 07/25/2022 | conversations bug fixes |
1169
1171
  | 4.0.40-RC | 07/25/2022 | conversations - add a websocket message model |
1170
1172
  | 4.0.39-RC | 07/21/2022 | conversation response types improvements |
1171
1173
  | 4.0.38-RC | 07/21/2022 | conversation bugfix for poor response objects |
@@ -0,0 +1,20 @@
1
+ # UltracartClient::ConversationEventQueuePosition
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **available** | **Boolean** | True if agents are logged into the queue | [optional] |
8
+ | **position** | **Integer** | Position in the queue. Value will be -1 if they cant be found in the queue. | [optional] |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'ultracart_api'
14
+
15
+ instance = UltracartClient::ConversationEventQueuePosition.new(
16
+ available: null,
17
+ position: null
18
+ )
19
+ ```
20
+
@@ -7,8 +7,8 @@
7
7
  | **conversation_uuid** | **String** | Conversation UUID if the websocket message is tied to a specific conversation | [optional] |
8
8
  | **event_conversation_closed** | [**Conversation**](Conversation.md) | | [optional] |
9
9
  | **event_new_conversation** | [**Conversation**](Conversation.md) | | [optional] |
10
- | **event_new_message** | [**ConversationMessage**](ConversationMessage.md) | | [optional] |
11
- | **event_queue_position** | **Object** | | [optional] |
10
+ | **event_new_message** | [**Conversation**](Conversation.md) | | [optional] |
11
+ | **event_queue_position** | [**ConversationEventQueuePosition**](ConversationEventQueuePosition.md) | | [optional] |
12
12
  | **event_type** | **String** | Type of event | [optional] |
13
13
  | **event_updated_message** | [**ConversationMessage**](ConversationMessage.md) | | [optional] |
14
14
  | **message** | [**ConversationMessage**](ConversationMessage.md) | | [optional] |
@@ -0,0 +1,230 @@
1
+ =begin
2
+ #UltraCart Rest API V2
3
+
4
+ #UltraCart REST API Version 2
5
+
6
+ The version of the OpenAPI document: 2.0.0
7
+ Contact: support@ultracart.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.0.1-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module UltracartClient
17
+ class ConversationEventQueuePosition
18
+ # True if agents are logged into the queue
19
+ attr_accessor :available
20
+
21
+ # Position in the queue. Value will be -1 if they cant be found in the queue.
22
+ attr_accessor :position
23
+
24
+ # Attribute mapping from ruby-style variable name to JSON key.
25
+ def self.attribute_map
26
+ {
27
+ :'available' => :'available',
28
+ :'position' => :'position'
29
+ }
30
+ end
31
+
32
+ # Returns all the JSON keys this model knows about
33
+ def self.acceptable_attributes
34
+ attribute_map.values
35
+ end
36
+
37
+ # Attribute type mapping.
38
+ def self.openapi_types
39
+ {
40
+ :'available' => :'Boolean',
41
+ :'position' => :'Integer'
42
+ }
43
+ end
44
+
45
+ # List of attributes with nullable: true
46
+ def self.openapi_nullable
47
+ Set.new([
48
+ ])
49
+ end
50
+
51
+ # Initializes the object
52
+ # @param [Hash] attributes Model attributes in the form of hash
53
+ def initialize(attributes = {})
54
+ if (!attributes.is_a?(Hash))
55
+ fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::ConversationEventQueuePosition` initialize method"
56
+ end
57
+
58
+ # check to see if the attribute exists and convert string to symbol for hash key
59
+ attributes = attributes.each_with_object({}) { |(k, v), h|
60
+ if (!self.class.attribute_map.key?(k.to_sym))
61
+ fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::ConversationEventQueuePosition`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
62
+ end
63
+ h[k.to_sym] = v
64
+ }
65
+
66
+ if attributes.key?(:'available')
67
+ self.available = attributes[:'available']
68
+ end
69
+
70
+ if attributes.key?(:'position')
71
+ self.position = attributes[:'position']
72
+ end
73
+ end
74
+
75
+ # Show invalid properties with the reasons. Usually used together with valid?
76
+ # @return Array for valid properties with the reasons
77
+ def list_invalid_properties
78
+ invalid_properties = Array.new
79
+ invalid_properties
80
+ end
81
+
82
+ # Check to see if the all the properties in the model are valid
83
+ # @return true if the model is valid
84
+ def valid?
85
+ true
86
+ end
87
+
88
+ # Checks equality by comparing each attribute.
89
+ # @param [Object] Object to be compared
90
+ def ==(o)
91
+ return true if self.equal?(o)
92
+ self.class == o.class &&
93
+ available == o.available &&
94
+ position == o.position
95
+ end
96
+
97
+ # @see the `==` method
98
+ # @param [Object] Object to be compared
99
+ def eql?(o)
100
+ self == o
101
+ end
102
+
103
+ # Calculates hash code according to all attributes.
104
+ # @return [Integer] Hash code
105
+ def hash
106
+ [available, position].hash
107
+ end
108
+
109
+ # Builds the object from hash
110
+ # @param [Hash] attributes Model attributes in the form of hash
111
+ # @return [Object] Returns the model itself
112
+ def self.build_from_hash(attributes)
113
+ new.build_from_hash(attributes)
114
+ end
115
+
116
+ # Builds the object from hash
117
+ # @param [Hash] attributes Model attributes in the form of hash
118
+ # @return [Object] Returns the model itself
119
+ def build_from_hash(attributes)
120
+ return nil unless attributes.is_a?(Hash)
121
+ attributes = attributes.transform_keys(&:to_sym)
122
+ self.class.openapi_types.each_pair do |key, type|
123
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
124
+ self.send("#{key}=", nil)
125
+ elsif type =~ /\AArray<(.*)>/i
126
+ # check to ensure the input is an array given that the attribute
127
+ # is documented as an array but the input is not
128
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
129
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
130
+ end
131
+ elsif !attributes[self.class.attribute_map[key]].nil?
132
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
133
+ end
134
+ end
135
+
136
+ self
137
+ end
138
+
139
+ # Deserializes the data based on type
140
+ # @param string type Data type
141
+ # @param string value Value to be deserialized
142
+ # @return [Object] Deserialized data
143
+ def _deserialize(type, value)
144
+ case type.to_sym
145
+ when :Time
146
+ Time.parse(value)
147
+ when :Date
148
+ Date.parse(value)
149
+ when :String
150
+ value.to_s
151
+ when :Integer
152
+ value.to_i
153
+ when :Float
154
+ value.to_f
155
+ when :Boolean
156
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
157
+ true
158
+ else
159
+ false
160
+ end
161
+ when :Object
162
+ # generic object (usually a Hash), return directly
163
+ value
164
+ when /\AArray<(?<inner_type>.+)>\z/
165
+ inner_type = Regexp.last_match[:inner_type]
166
+ value.map { |v| _deserialize(inner_type, v) }
167
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
168
+ k_type = Regexp.last_match[:k_type]
169
+ v_type = Regexp.last_match[:v_type]
170
+ {}.tap do |hash|
171
+ value.each do |k, v|
172
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
173
+ end
174
+ end
175
+ else # model
176
+ # models (e.g. Pet) or oneOf
177
+ klass = UltracartClient.const_get(type)
178
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
179
+ end
180
+ end
181
+
182
+ # Returns the string representation of the object
183
+ # @return [String] String presentation of the object
184
+ def to_s
185
+ to_hash.to_s
186
+ end
187
+
188
+ # to_body is an alias to to_hash (backward compatibility)
189
+ # @return [Hash] Returns the object in the form of hash
190
+ def to_body
191
+ to_hash
192
+ end
193
+
194
+ # Returns the object in the form of hash
195
+ # @return [Hash] Returns the object in the form of hash
196
+ def to_hash
197
+ hash = {}
198
+ self.class.attribute_map.each_pair do |attr, param|
199
+ value = self.send(attr)
200
+ if value.nil?
201
+ is_nullable = self.class.openapi_nullable.include?(attr)
202
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
203
+ end
204
+
205
+ hash[param] = _to_hash(value)
206
+ end
207
+ hash
208
+ end
209
+
210
+ # Outputs non-array value in the form of hash
211
+ # For object, use to_hash. Otherwise, just return the value
212
+ # @param [Object] value Any valid value
213
+ # @return [Hash] Returns the value in the form of hash
214
+ def _to_hash(value)
215
+ if value.is_a?(Array)
216
+ value.compact.map { |v| _to_hash(v) }
217
+ elsif value.is_a?(Hash)
218
+ {}.tap do |hash|
219
+ value.each { |k, v| hash[k] = _to_hash(v) }
220
+ end
221
+ elsif value.respond_to? :to_hash
222
+ value.to_hash
223
+ else
224
+ value
225
+ end
226
+ end
227
+
228
+ end
229
+
230
+ end
@@ -84,8 +84,8 @@ module UltracartClient
84
84
  :'conversation_uuid' => :'String',
85
85
  :'event_conversation_closed' => :'Conversation',
86
86
  :'event_new_conversation' => :'Conversation',
87
- :'event_new_message' => :'ConversationMessage',
88
- :'event_queue_position' => :'Object',
87
+ :'event_new_message' => :'Conversation',
88
+ :'event_queue_position' => :'ConversationEventQueuePosition',
89
89
  :'event_type' => :'String',
90
90
  :'event_updated_message' => :'ConversationMessage',
91
91
  :'message' => :'ConversationMessage',
@@ -11,5 +11,5 @@ OpenAPI Generator version: 6.0.1-SNAPSHOT
11
11
  =end
12
12
 
13
13
  module UltracartClient
14
- VERSION = '4.0.40.rc'
14
+ VERSION = '4.0.41.rc'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -137,6 +137,7 @@ require 'ultracart_api/models/city_state_zip'
137
137
  require 'ultracart_api/models/conversation'
138
138
  require 'ultracart_api/models/conversation_agent_auth'
139
139
  require 'ultracart_api/models/conversation_agent_auth_response'
140
+ require 'ultracart_api/models/conversation_event_queue_position'
140
141
  require 'ultracart_api/models/conversation_message'
141
142
  require 'ultracart_api/models/conversation_message_transport_status'
142
143
  require 'ultracart_api/models/conversation_multimedia_upload_url'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ultracart_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.40.rc
4
+ version: 4.0.41.rc
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
@@ -187,6 +187,7 @@ files:
187
187
  - docs/ConversationAgentAuth.md
188
188
  - docs/ConversationAgentAuthResponse.md
189
189
  - docs/ConversationApi.md
190
+ - docs/ConversationEventQueuePosition.md
190
191
  - docs/ConversationMessage.md
191
192
  - docs/ConversationMessageTransportStatus.md
192
193
  - docs/ConversationMultimediaUploadUrl.md
@@ -872,6 +873,7 @@ files:
872
873
  - lib/ultracart_api/models/conversation.rb
873
874
  - lib/ultracart_api/models/conversation_agent_auth.rb
874
875
  - lib/ultracart_api/models/conversation_agent_auth_response.rb
876
+ - lib/ultracart_api/models/conversation_event_queue_position.rb
875
877
  - lib/ultracart_api/models/conversation_message.rb
876
878
  - lib/ultracart_api/models/conversation_message_transport_status.rb
877
879
  - lib/ultracart_api/models/conversation_multimedia_upload_url.rb