ultracart_api 4.0.137 → 4.0.138
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 +6 -4
- data/docs/Conversation.md +2 -0
- data/docs/ConversationSentiment.md +28 -0
- data/docs/ConversationSummary.md +2 -0
- data/lib/ultracart_api/models/conversation.rb +10 -1
- data/lib/ultracart_api/models/conversation_sentiment.rb +304 -0
- data/lib/ultracart_api/models/conversation_summary.rb +10 -1
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +1 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fa5f2374106efb08b3ea023776ff2022f925d0d4af3cc8e0d5953fbae8c9d781
|
4
|
+
data.tar.gz: 5f7f8723cb8fa2ad2ce67f25d91bc37a603a943a40c7ed3476ceb8080498adb5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3c0d2a2f0c601e33fbb12872613b1d4b0fa0d9781d2e828aff746f415a93f5606006f1905b9f2b1ee58dc12aaafdca0ba04a1a1dcc6b1c5e24a9f1f29cb84aa4
|
7
|
+
data.tar.gz: f2b70b07493cd04ebc39d5d7215274e1488a1e1b26503daf499d7a3b30a6b68e7be4021b7590e15379f557e0f33750ed8a43acaeffc8978e078b9133491e7a6a
|
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.
|
10
|
+
- Package version: 4.0.138
|
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.
|
27
|
+
gem install ./ultracart_api-4.0.138.gem
|
28
28
|
```
|
29
29
|
|
30
|
-
(for development, run `gem install --dev ./ultracart_api-4.0.
|
30
|
+
(for development, run `gem install --dev ./ultracart_api-4.0.138.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.
|
36
|
+
gem 'ultracart_api', '~> 4.0.138'
|
37
37
|
|
38
38
|
### Install from Git
|
39
39
|
|
@@ -668,6 +668,7 @@ Class | Method | HTTP request | Description
|
|
668
668
|
- [UltracartClient::ConversationResponse](docs/ConversationResponse.md)
|
669
669
|
- [UltracartClient::ConversationSearchRequest](docs/ConversationSearchRequest.md)
|
670
670
|
- [UltracartClient::ConversationSearchResponse](docs/ConversationSearchResponse.md)
|
671
|
+
- [UltracartClient::ConversationSentiment](docs/ConversationSentiment.md)
|
671
672
|
- [UltracartClient::ConversationStartRequest](docs/ConversationStartRequest.md)
|
672
673
|
- [UltracartClient::ConversationStartResponse](docs/ConversationStartResponse.md)
|
673
674
|
- [UltracartClient::ConversationSummary](docs/ConversationSummary.md)
|
@@ -1311,6 +1312,7 @@ Not every change is committed to every SDK.
|
|
1311
1312
|
|
1312
1313
|
| Version | Date | Comments |
|
1313
1314
|
| --: | :-: | --- |
|
1315
|
+
| 4.0.138 | 03/01/2023 | convo - add sentiment record to conversation obj |
|
1314
1316
|
| 4.0.137 | 02/22/2023 | convo - customer initiated flag on engagement |
|
1315
1317
|
| 4.0.136 | 02/20/2023 | refund reasons |
|
1316
1318
|
| 4.0.135 | 02/17/2023 | convo api - smsUnsubscribeConversation method |
|
data/docs/Conversation.md
CHANGED
@@ -19,6 +19,7 @@
|
|
19
19
|
| **message_count** | **Integer** | | [optional] |
|
20
20
|
| **messages** | [**Array<ConversationMessage>**](ConversationMessage.md) | | [optional] |
|
21
21
|
| **participants** | [**Array<ConversationParticipant>**](ConversationParticipant.md) | | [optional] |
|
22
|
+
| **sentiment** | [**ConversationSentiment**](ConversationSentiment.md) | | [optional] |
|
22
23
|
| **start_dts** | **String** | Start of the conversation date/time | [optional] |
|
23
24
|
| **unread_messages** | **Boolean** | | [optional] |
|
24
25
|
| **visible** | **Boolean** | | [optional] |
|
@@ -44,6 +45,7 @@ instance = UltracartClient::Conversation.new(
|
|
44
45
|
message_count: null,
|
45
46
|
messages: null,
|
46
47
|
participants: null,
|
48
|
+
sentiment: null,
|
47
49
|
start_dts: null,
|
48
50
|
unread_messages: null,
|
49
51
|
visible: null
|
@@ -0,0 +1,28 @@
|
|
1
|
+
# UltracartClient::ConversationSentiment
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **last_detect_sentiment** | **String** | The last time the detect sentiment was run on this conversation | [optional] |
|
8
|
+
| **mixed** | **Float** | The mixed score | [optional] |
|
9
|
+
| **negative** | **Float** | The negative score | [optional] |
|
10
|
+
| **neutral** | **Float** | The neutral score | [optional] |
|
11
|
+
| **positive** | **Float** | The positive score | [optional] |
|
12
|
+
| **sentiment** | **String** | The overall sentiment | [optional] |
|
13
|
+
|
14
|
+
## Example
|
15
|
+
|
16
|
+
```ruby
|
17
|
+
require 'ultracart_api'
|
18
|
+
|
19
|
+
instance = UltracartClient::ConversationSentiment.new(
|
20
|
+
last_detect_sentiment: null,
|
21
|
+
mixed: null,
|
22
|
+
negative: null,
|
23
|
+
neutral: null,
|
24
|
+
positive: null,
|
25
|
+
sentiment: null
|
26
|
+
)
|
27
|
+
```
|
28
|
+
|
data/docs/ConversationSummary.md
CHANGED
@@ -17,6 +17,7 @@
|
|
17
17
|
| **merchant_id** | **String** | | [optional] |
|
18
18
|
| **message_count** | **Integer** | | [optional] |
|
19
19
|
| **participants** | [**Array<ConversationParticipant>**](ConversationParticipant.md) | | [optional] |
|
20
|
+
| **sentiment** | [**ConversationSentiment**](ConversationSentiment.md) | | [optional] |
|
20
21
|
| **start_dts** | **String** | Start of the conversation date/time | [optional] |
|
21
22
|
| **unread_messages** | **Boolean** | | [optional] |
|
22
23
|
| **visible** | **Boolean** | | [optional] |
|
@@ -40,6 +41,7 @@ instance = UltracartClient::ConversationSummary.new(
|
|
40
41
|
merchant_id: null,
|
41
42
|
message_count: null,
|
42
43
|
participants: null,
|
44
|
+
sentiment: null,
|
43
45
|
start_dts: null,
|
44
46
|
unread_messages: null,
|
45
47
|
visible: null
|
@@ -50,6 +50,8 @@ module UltracartClient
|
|
50
50
|
|
51
51
|
attr_accessor :participants
|
52
52
|
|
53
|
+
attr_accessor :sentiment
|
54
|
+
|
53
55
|
# Start of the conversation date/time
|
54
56
|
attr_accessor :start_dts
|
55
57
|
|
@@ -97,6 +99,7 @@ module UltracartClient
|
|
97
99
|
:'message_count' => :'message_count',
|
98
100
|
:'messages' => :'messages',
|
99
101
|
:'participants' => :'participants',
|
102
|
+
:'sentiment' => :'sentiment',
|
100
103
|
:'start_dts' => :'start_dts',
|
101
104
|
:'unread_messages' => :'unread_messages',
|
102
105
|
:'visible' => :'visible'
|
@@ -126,6 +129,7 @@ module UltracartClient
|
|
126
129
|
:'message_count' => :'Integer',
|
127
130
|
:'messages' => :'Array<ConversationMessage>',
|
128
131
|
:'participants' => :'Array<ConversationParticipant>',
|
132
|
+
:'sentiment' => :'ConversationSentiment',
|
129
133
|
:'start_dts' => :'String',
|
130
134
|
:'unread_messages' => :'Boolean',
|
131
135
|
:'visible' => :'Boolean'
|
@@ -217,6 +221,10 @@ module UltracartClient
|
|
217
221
|
end
|
218
222
|
end
|
219
223
|
|
224
|
+
if attributes.key?(:'sentiment')
|
225
|
+
self.sentiment = attributes[:'sentiment']
|
226
|
+
end
|
227
|
+
|
220
228
|
if attributes.key?(:'start_dts')
|
221
229
|
self.start_dts = attributes[:'start_dts']
|
222
230
|
end
|
@@ -275,6 +283,7 @@ module UltracartClient
|
|
275
283
|
message_count == o.message_count &&
|
276
284
|
messages == o.messages &&
|
277
285
|
participants == o.participants &&
|
286
|
+
sentiment == o.sentiment &&
|
278
287
|
start_dts == o.start_dts &&
|
279
288
|
unread_messages == o.unread_messages &&
|
280
289
|
visible == o.visible
|
@@ -289,7 +298,7 @@ module UltracartClient
|
|
289
298
|
# Calculates hash code according to all attributes.
|
290
299
|
# @return [Integer] Hash code
|
291
300
|
def hash
|
292
|
-
[base_language_iso_code, closed, conversation_arn, conversation_uuid, customer_first_message_unresponded_to_dts, last_conversation_message_body, last_conversation_participant_arn, last_conversation_participant_name, last_interactive_message_dts, last_message_dts, medium, merchant_id, message_count, messages, participants, start_dts, unread_messages, visible].hash
|
301
|
+
[base_language_iso_code, closed, conversation_arn, conversation_uuid, customer_first_message_unresponded_to_dts, last_conversation_message_body, last_conversation_participant_arn, last_conversation_participant_name, last_interactive_message_dts, last_message_dts, medium, merchant_id, message_count, messages, participants, sentiment, start_dts, unread_messages, visible].hash
|
293
302
|
end
|
294
303
|
|
295
304
|
# Builds the object from hash
|
@@ -0,0 +1,304 @@
|
|
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 ConversationSentiment
|
18
|
+
# The last time the detect sentiment was run on this conversation
|
19
|
+
attr_accessor :last_detect_sentiment
|
20
|
+
|
21
|
+
# The mixed score
|
22
|
+
attr_accessor :mixed
|
23
|
+
|
24
|
+
# The negative score
|
25
|
+
attr_accessor :negative
|
26
|
+
|
27
|
+
# The neutral score
|
28
|
+
attr_accessor :neutral
|
29
|
+
|
30
|
+
# The positive score
|
31
|
+
attr_accessor :positive
|
32
|
+
|
33
|
+
# The overall sentiment
|
34
|
+
attr_accessor :sentiment
|
35
|
+
|
36
|
+
class EnumAttributeValidator
|
37
|
+
attr_reader :datatype
|
38
|
+
attr_reader :allowable_values
|
39
|
+
|
40
|
+
def initialize(datatype, allowable_values)
|
41
|
+
@allowable_values = allowable_values.map do |value|
|
42
|
+
case datatype.to_s
|
43
|
+
when /Integer/i
|
44
|
+
value.to_i
|
45
|
+
when /Float/i
|
46
|
+
value.to_f
|
47
|
+
else
|
48
|
+
value
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
52
|
+
|
53
|
+
def valid?(value)
|
54
|
+
!value || allowable_values.include?(value)
|
55
|
+
end
|
56
|
+
end
|
57
|
+
|
58
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
59
|
+
def self.attribute_map
|
60
|
+
{
|
61
|
+
:'last_detect_sentiment' => :'last_detect_sentiment',
|
62
|
+
:'mixed' => :'mixed',
|
63
|
+
:'negative' => :'negative',
|
64
|
+
:'neutral' => :'neutral',
|
65
|
+
:'positive' => :'positive',
|
66
|
+
:'sentiment' => :'sentiment'
|
67
|
+
}
|
68
|
+
end
|
69
|
+
|
70
|
+
# Returns all the JSON keys this model knows about
|
71
|
+
def self.acceptable_attributes
|
72
|
+
attribute_map.values
|
73
|
+
end
|
74
|
+
|
75
|
+
# Attribute type mapping.
|
76
|
+
def self.openapi_types
|
77
|
+
{
|
78
|
+
:'last_detect_sentiment' => :'String',
|
79
|
+
:'mixed' => :'Float',
|
80
|
+
:'negative' => :'Float',
|
81
|
+
:'neutral' => :'Float',
|
82
|
+
:'positive' => :'Float',
|
83
|
+
:'sentiment' => :'String'
|
84
|
+
}
|
85
|
+
end
|
86
|
+
|
87
|
+
# List of attributes with nullable: true
|
88
|
+
def self.openapi_nullable
|
89
|
+
Set.new([
|
90
|
+
])
|
91
|
+
end
|
92
|
+
|
93
|
+
# Initializes the object
|
94
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
95
|
+
def initialize(attributes = {})
|
96
|
+
if (!attributes.is_a?(Hash))
|
97
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::ConversationSentiment` initialize method"
|
98
|
+
end
|
99
|
+
|
100
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
101
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
102
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
103
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::ConversationSentiment`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
104
|
+
end
|
105
|
+
h[k.to_sym] = v
|
106
|
+
}
|
107
|
+
|
108
|
+
if attributes.key?(:'last_detect_sentiment')
|
109
|
+
self.last_detect_sentiment = attributes[:'last_detect_sentiment']
|
110
|
+
end
|
111
|
+
|
112
|
+
if attributes.key?(:'mixed')
|
113
|
+
self.mixed = attributes[:'mixed']
|
114
|
+
end
|
115
|
+
|
116
|
+
if attributes.key?(:'negative')
|
117
|
+
self.negative = attributes[:'negative']
|
118
|
+
end
|
119
|
+
|
120
|
+
if attributes.key?(:'neutral')
|
121
|
+
self.neutral = attributes[:'neutral']
|
122
|
+
end
|
123
|
+
|
124
|
+
if attributes.key?(:'positive')
|
125
|
+
self.positive = attributes[:'positive']
|
126
|
+
end
|
127
|
+
|
128
|
+
if attributes.key?(:'sentiment')
|
129
|
+
self.sentiment = attributes[:'sentiment']
|
130
|
+
end
|
131
|
+
end
|
132
|
+
|
133
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
134
|
+
# @return Array for valid properties with the reasons
|
135
|
+
def list_invalid_properties
|
136
|
+
invalid_properties = Array.new
|
137
|
+
invalid_properties
|
138
|
+
end
|
139
|
+
|
140
|
+
# Check to see if the all the properties in the model are valid
|
141
|
+
# @return true if the model is valid
|
142
|
+
def valid?
|
143
|
+
sentiment_validator = EnumAttributeValidator.new('String', ["POSITIVE", "NEUTRAL", "NEGATIVE", "MIXED"])
|
144
|
+
return false unless sentiment_validator.valid?(@sentiment)
|
145
|
+
true
|
146
|
+
end
|
147
|
+
|
148
|
+
# Custom attribute writer method checking allowed values (enum).
|
149
|
+
# @param [Object] sentiment Object to be assigned
|
150
|
+
def sentiment=(sentiment)
|
151
|
+
validator = EnumAttributeValidator.new('String', ["POSITIVE", "NEUTRAL", "NEGATIVE", "MIXED"])
|
152
|
+
unless validator.valid?(sentiment)
|
153
|
+
fail ArgumentError, "invalid value for \"sentiment\", must be one of #{validator.allowable_values}."
|
154
|
+
end
|
155
|
+
@sentiment = sentiment
|
156
|
+
end
|
157
|
+
|
158
|
+
# Checks equality by comparing each attribute.
|
159
|
+
# @param [Object] Object to be compared
|
160
|
+
def ==(o)
|
161
|
+
return true if self.equal?(o)
|
162
|
+
self.class == o.class &&
|
163
|
+
last_detect_sentiment == o.last_detect_sentiment &&
|
164
|
+
mixed == o.mixed &&
|
165
|
+
negative == o.negative &&
|
166
|
+
neutral == o.neutral &&
|
167
|
+
positive == o.positive &&
|
168
|
+
sentiment == o.sentiment
|
169
|
+
end
|
170
|
+
|
171
|
+
# @see the `==` method
|
172
|
+
# @param [Object] Object to be compared
|
173
|
+
def eql?(o)
|
174
|
+
self == o
|
175
|
+
end
|
176
|
+
|
177
|
+
# Calculates hash code according to all attributes.
|
178
|
+
# @return [Integer] Hash code
|
179
|
+
def hash
|
180
|
+
[last_detect_sentiment, mixed, negative, neutral, positive, sentiment].hash
|
181
|
+
end
|
182
|
+
|
183
|
+
# Builds the object from hash
|
184
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
185
|
+
# @return [Object] Returns the model itself
|
186
|
+
def self.build_from_hash(attributes)
|
187
|
+
new.build_from_hash(attributes)
|
188
|
+
end
|
189
|
+
|
190
|
+
# Builds the object from hash
|
191
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
192
|
+
# @return [Object] Returns the model itself
|
193
|
+
def build_from_hash(attributes)
|
194
|
+
return nil unless attributes.is_a?(Hash)
|
195
|
+
attributes = attributes.transform_keys(&:to_sym)
|
196
|
+
self.class.openapi_types.each_pair do |key, type|
|
197
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
198
|
+
self.send("#{key}=", nil)
|
199
|
+
elsif type =~ /\AArray<(.*)>/i
|
200
|
+
# check to ensure the input is an array given that the attribute
|
201
|
+
# is documented as an array but the input is not
|
202
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
203
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
204
|
+
end
|
205
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
206
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
207
|
+
end
|
208
|
+
end
|
209
|
+
|
210
|
+
self
|
211
|
+
end
|
212
|
+
|
213
|
+
# Deserializes the data based on type
|
214
|
+
# @param string type Data type
|
215
|
+
# @param string value Value to be deserialized
|
216
|
+
# @return [Object] Deserialized data
|
217
|
+
def _deserialize(type, value)
|
218
|
+
case type.to_sym
|
219
|
+
when :Time
|
220
|
+
Time.parse(value)
|
221
|
+
when :Date
|
222
|
+
Date.parse(value)
|
223
|
+
when :String
|
224
|
+
value.to_s
|
225
|
+
when :Integer
|
226
|
+
value.to_i
|
227
|
+
when :Float
|
228
|
+
value.to_f
|
229
|
+
when :Boolean
|
230
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
231
|
+
true
|
232
|
+
else
|
233
|
+
false
|
234
|
+
end
|
235
|
+
when :Object
|
236
|
+
# generic object (usually a Hash), return directly
|
237
|
+
value
|
238
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
239
|
+
inner_type = Regexp.last_match[:inner_type]
|
240
|
+
value.map { |v| _deserialize(inner_type, v) }
|
241
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
242
|
+
k_type = Regexp.last_match[:k_type]
|
243
|
+
v_type = Regexp.last_match[:v_type]
|
244
|
+
{}.tap do |hash|
|
245
|
+
value.each do |k, v|
|
246
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
247
|
+
end
|
248
|
+
end
|
249
|
+
else # model
|
250
|
+
# models (e.g. Pet) or oneOf
|
251
|
+
klass = UltracartClient.const_get(type)
|
252
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
253
|
+
end
|
254
|
+
end
|
255
|
+
|
256
|
+
# Returns the string representation of the object
|
257
|
+
# @return [String] String presentation of the object
|
258
|
+
def to_s
|
259
|
+
to_hash.to_s
|
260
|
+
end
|
261
|
+
|
262
|
+
# to_body is an alias to to_hash (backward compatibility)
|
263
|
+
# @return [Hash] Returns the object in the form of hash
|
264
|
+
def to_body
|
265
|
+
to_hash
|
266
|
+
end
|
267
|
+
|
268
|
+
# Returns the object in the form of hash
|
269
|
+
# @return [Hash] Returns the object in the form of hash
|
270
|
+
def to_hash
|
271
|
+
hash = {}
|
272
|
+
self.class.attribute_map.each_pair do |attr, param|
|
273
|
+
value = self.send(attr)
|
274
|
+
if value.nil?
|
275
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
276
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
277
|
+
end
|
278
|
+
|
279
|
+
hash[param] = _to_hash(value)
|
280
|
+
end
|
281
|
+
hash
|
282
|
+
end
|
283
|
+
|
284
|
+
# Outputs non-array value in the form of hash
|
285
|
+
# For object, use to_hash. Otherwise, just return the value
|
286
|
+
# @param [Object] value Any valid value
|
287
|
+
# @return [Hash] Returns the value in the form of hash
|
288
|
+
def _to_hash(value)
|
289
|
+
if value.is_a?(Array)
|
290
|
+
value.compact.map { |v| _to_hash(v) }
|
291
|
+
elsif value.is_a?(Hash)
|
292
|
+
{}.tap do |hash|
|
293
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
294
|
+
end
|
295
|
+
elsif value.respond_to? :to_hash
|
296
|
+
value.to_hash
|
297
|
+
else
|
298
|
+
value
|
299
|
+
end
|
300
|
+
end
|
301
|
+
|
302
|
+
end
|
303
|
+
|
304
|
+
end
|
@@ -45,6 +45,8 @@ module UltracartClient
|
|
45
45
|
|
46
46
|
attr_accessor :participants
|
47
47
|
|
48
|
+
attr_accessor :sentiment
|
49
|
+
|
48
50
|
# Start of the conversation date/time
|
49
51
|
attr_accessor :start_dts
|
50
52
|
|
@@ -90,6 +92,7 @@ module UltracartClient
|
|
90
92
|
:'merchant_id' => :'merchant_id',
|
91
93
|
:'message_count' => :'message_count',
|
92
94
|
:'participants' => :'participants',
|
95
|
+
:'sentiment' => :'sentiment',
|
93
96
|
:'start_dts' => :'start_dts',
|
94
97
|
:'unread_messages' => :'unread_messages',
|
95
98
|
:'visible' => :'visible'
|
@@ -117,6 +120,7 @@ module UltracartClient
|
|
117
120
|
:'merchant_id' => :'String',
|
118
121
|
:'message_count' => :'Integer',
|
119
122
|
:'participants' => :'Array<ConversationParticipant>',
|
123
|
+
:'sentiment' => :'ConversationSentiment',
|
120
124
|
:'start_dts' => :'String',
|
121
125
|
:'unread_messages' => :'Boolean',
|
122
126
|
:'visible' => :'Boolean'
|
@@ -198,6 +202,10 @@ module UltracartClient
|
|
198
202
|
end
|
199
203
|
end
|
200
204
|
|
205
|
+
if attributes.key?(:'sentiment')
|
206
|
+
self.sentiment = attributes[:'sentiment']
|
207
|
+
end
|
208
|
+
|
201
209
|
if attributes.key?(:'start_dts')
|
202
210
|
self.start_dts = attributes[:'start_dts']
|
203
211
|
end
|
@@ -254,6 +262,7 @@ module UltracartClient
|
|
254
262
|
merchant_id == o.merchant_id &&
|
255
263
|
message_count == o.message_count &&
|
256
264
|
participants == o.participants &&
|
265
|
+
sentiment == o.sentiment &&
|
257
266
|
start_dts == o.start_dts &&
|
258
267
|
unread_messages == o.unread_messages &&
|
259
268
|
visible == o.visible
|
@@ -268,7 +277,7 @@ module UltracartClient
|
|
268
277
|
# Calculates hash code according to all attributes.
|
269
278
|
# @return [Integer] Hash code
|
270
279
|
def hash
|
271
|
-
[closed, conversation_arn, conversation_uuid, customer_first_message_unresponded_to_dts, last_conversation_message_body, last_conversation_participant_arn, last_conversation_participant_name, last_interactive_message_dts, last_message_dts, medium, merchant_id, message_count, participants, start_dts, unread_messages, visible].hash
|
280
|
+
[closed, conversation_arn, conversation_uuid, customer_first_message_unresponded_to_dts, last_conversation_message_body, last_conversation_participant_arn, last_conversation_participant_name, last_interactive_message_dts, last_message_dts, medium, merchant_id, message_count, participants, sentiment, start_dts, unread_messages, visible].hash
|
272
281
|
end
|
273
282
|
|
274
283
|
# Builds the object from hash
|
data/lib/ultracart_api.rb
CHANGED
@@ -186,6 +186,7 @@ require 'ultracart_api/models/conversation_permissions_response'
|
|
186
186
|
require 'ultracart_api/models/conversation_response'
|
187
187
|
require 'ultracart_api/models/conversation_search_request'
|
188
188
|
require 'ultracart_api/models/conversation_search_response'
|
189
|
+
require 'ultracart_api/models/conversation_sentiment'
|
189
190
|
require 'ultracart_api/models/conversation_start_request'
|
190
191
|
require 'ultracart_api/models/conversation_start_response'
|
191
192
|
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: 4.0.
|
4
|
+
version: 4.0.138
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- UltraCart
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-03-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -236,6 +236,7 @@ files:
|
|
236
236
|
- docs/ConversationResponse.md
|
237
237
|
- docs/ConversationSearchRequest.md
|
238
238
|
- docs/ConversationSearchResponse.md
|
239
|
+
- docs/ConversationSentiment.md
|
239
240
|
- docs/ConversationStartRequest.md
|
240
241
|
- docs/ConversationStartResponse.md
|
241
242
|
- docs/ConversationSummary.md
|
@@ -1012,6 +1013,7 @@ files:
|
|
1012
1013
|
- lib/ultracart_api/models/conversation_response.rb
|
1013
1014
|
- lib/ultracart_api/models/conversation_search_request.rb
|
1014
1015
|
- lib/ultracart_api/models/conversation_search_response.rb
|
1016
|
+
- lib/ultracart_api/models/conversation_sentiment.rb
|
1015
1017
|
- lib/ultracart_api/models/conversation_start_request.rb
|
1016
1018
|
- lib/ultracart_api/models/conversation_start_response.rb
|
1017
1019
|
- lib/ultracart_api/models/conversation_summary.rb
|