ultracart_api 3.10.65 → 3.10.67
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +8 -4
- data/docs/ConversationEventAddCoupon.md +8 -0
- data/docs/ConversationEventAddItem.md +8 -0
- data/docs/ConversationWebsocketMessage.md +2 -0
- data/docs/OrderRefundableResponse.md +1 -1
- data/lib/ultracart_api/models/conversation_event_add_coupon.rb +184 -0
- data/lib/ultracart_api/models/conversation_event_add_item.rb +184 -0
- data/lib/ultracart_api/models/conversation_websocket_message.rb +21 -3
- data/lib/ultracart_api/models/order_property.rb +5 -5
- data/lib/ultracart_api/models/order_refundable_response.rb +1 -1
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +2 -0
- metadata +5 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3cd99056d1cc2ccd249f1b68f272737a016e18567aa22a93ed78909bf61b6302
|
4
|
+
data.tar.gz: fcc68320ca92c20e6423b8122af52ccb54f9a300358f2bd0fe94f0fb6366f3bd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9ad83e934b3a4705718fc4906b8ecaa6214630a1c2030e3a588a866af4da3494e9c83d1bb21f7636994987dca8cb660ae1b11f004a61054982271cf1458a21ba
|
7
|
+
data.tar.gz: 194f95d200aff28dce57cbff57a0decc09d6280e3c69cba35b6a4f8e3582706dc2364c1dd4ece27d4cdac13efb71f6be14de039af94db836fbd0e0b51e654a0d
|
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.67
|
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.67.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.67.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.67'
|
36
36
|
|
37
37
|
### Install from Git
|
38
38
|
|
@@ -582,6 +582,8 @@ Class | Method | HTTP request | Description
|
|
582
582
|
- [UltracartClient::Conversation](docs/Conversation.md)
|
583
583
|
- [UltracartClient::ConversationAgentAuth](docs/ConversationAgentAuth.md)
|
584
584
|
- [UltracartClient::ConversationAgentAuthResponse](docs/ConversationAgentAuthResponse.md)
|
585
|
+
- [UltracartClient::ConversationEventAddCoupon](docs/ConversationEventAddCoupon.md)
|
586
|
+
- [UltracartClient::ConversationEventAddItem](docs/ConversationEventAddItem.md)
|
585
587
|
- [UltracartClient::ConversationEventQueuePosition](docs/ConversationEventQueuePosition.md)
|
586
588
|
- [UltracartClient::ConversationEventRRWeb](docs/ConversationEventRRWeb.md)
|
587
589
|
- [UltracartClient::ConversationEventReadMessage](docs/ConversationEventReadMessage.md)
|
@@ -1215,6 +1217,8 @@ Not every change is committed to every SDK.
|
|
1215
1217
|
|
1216
1218
|
| Version | Date | Comments |
|
1217
1219
|
| --: | :-: | --- |
|
1220
|
+
| 3.10.67 | 11/15/2022 | conversation methods bug fix |
|
1221
|
+
| 3.10.66 | 11/15/2022 | conversations - enw events for add coupon and items |
|
1218
1222
|
| 3.10.65 | 11/15/2022 | order api new method is order refundable |
|
1219
1223
|
| 3.10.64 | 11/15/2022 | increase order property length to 10k char |
|
1220
1224
|
| 3.10.63 | 11/14/2022 | conversations - add allowed values for update agent status |
|
@@ -4,6 +4,8 @@
|
|
4
4
|
Name | Type | Description | Notes
|
5
5
|
------------ | ------------- | ------------- | -------------
|
6
6
|
**conversation_uuid** | **String** | Conversation UUID if the websocket message is tied to a specific conversation | [optional]
|
7
|
+
**event_add_coupon** | [**ConversationEventAddCoupon**](ConversationEventAddCoupon.md) | | [optional]
|
8
|
+
**event_add_item** | [**ConversationEventAddItem**](ConversationEventAddItem.md) | | [optional]
|
7
9
|
**event_conversation_closed** | [**ConversationSummary**](ConversationSummary.md) | | [optional]
|
8
10
|
**event_new_conversation** | [**ConversationSummary**](ConversationSummary.md) | | [optional]
|
9
11
|
**event_new_message** | [**ConversationSummary**](ConversationSummary.md) | | [optional]
|
@@ -5,7 +5,7 @@ Name | Type | Description | Notes
|
|
5
5
|
------------ | ------------- | ------------- | -------------
|
6
6
|
**error** | [**Error**](Error.md) | | [optional]
|
7
7
|
**metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional]
|
8
|
-
**refundable** | **BOOLEAN** | Whether the order is refundable or not. | [optional]
|
8
|
+
**refundable** | **BOOLEAN** | Whether the order is refundable or not. Null should be interpreted as false. | [optional]
|
9
9
|
**success** | **BOOLEAN** | Indicates if API call was successful | [optional]
|
10
10
|
**warning** | [**Warning**](Warning.md) | | [optional]
|
11
11
|
|
@@ -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 ConversationEventAddCoupon
|
17
|
+
attr_accessor :coupon_code
|
18
|
+
|
19
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
20
|
+
def self.attribute_map
|
21
|
+
{
|
22
|
+
:'coupon_code' => :'coupon_code'
|
23
|
+
}
|
24
|
+
end
|
25
|
+
|
26
|
+
# Attribute type mapping.
|
27
|
+
def self.swagger_types
|
28
|
+
{
|
29
|
+
:'coupon_code' => :'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?(:'coupon_code')
|
42
|
+
self.coupon_code = attributes[:'coupon_code']
|
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
|
+
coupon_code == o.coupon_code
|
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
|
+
[coupon_code].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,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 ConversationEventAddItem
|
17
|
+
attr_accessor :item_id
|
18
|
+
|
19
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
20
|
+
def self.attribute_map
|
21
|
+
{
|
22
|
+
:'item_id' => :'item_id'
|
23
|
+
}
|
24
|
+
end
|
25
|
+
|
26
|
+
# Attribute type mapping.
|
27
|
+
def self.swagger_types
|
28
|
+
{
|
29
|
+
:'item_id' => :'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?(:'item_id')
|
42
|
+
self.item_id = attributes[:'item_id']
|
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
|
+
item_id == o.item_id
|
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
|
+
[item_id].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
|
@@ -17,6 +17,10 @@ module UltracartClient
|
|
17
17
|
# Conversation UUID if the websocket message is tied to a specific conversation
|
18
18
|
attr_accessor :conversation_uuid
|
19
19
|
|
20
|
+
attr_accessor :event_add_coupon
|
21
|
+
|
22
|
+
attr_accessor :event_add_item
|
23
|
+
|
20
24
|
attr_accessor :event_conversation_closed
|
21
25
|
|
22
26
|
attr_accessor :event_new_conversation
|
@@ -71,6 +75,8 @@ module UltracartClient
|
|
71
75
|
def self.attribute_map
|
72
76
|
{
|
73
77
|
:'conversation_uuid' => :'conversation_uuid',
|
78
|
+
:'event_add_coupon' => :'event_add_coupon',
|
79
|
+
:'event_add_item' => :'event_add_item',
|
74
80
|
:'event_conversation_closed' => :'event_conversation_closed',
|
75
81
|
:'event_new_conversation' => :'event_new_conversation',
|
76
82
|
:'event_new_message' => :'event_new_message',
|
@@ -91,6 +97,8 @@ module UltracartClient
|
|
91
97
|
def self.swagger_types
|
92
98
|
{
|
93
99
|
:'conversation_uuid' => :'String',
|
100
|
+
:'event_add_coupon' => :'ConversationEventAddCoupon',
|
101
|
+
:'event_add_item' => :'ConversationEventAddItem',
|
94
102
|
:'event_conversation_closed' => :'ConversationSummary',
|
95
103
|
:'event_new_conversation' => :'ConversationSummary',
|
96
104
|
:'event_new_message' => :'ConversationSummary',
|
@@ -119,6 +127,14 @@ module UltracartClient
|
|
119
127
|
self.conversation_uuid = attributes[:'conversation_uuid']
|
120
128
|
end
|
121
129
|
|
130
|
+
if attributes.has_key?(:'event_add_coupon')
|
131
|
+
self.event_add_coupon = attributes[:'event_add_coupon']
|
132
|
+
end
|
133
|
+
|
134
|
+
if attributes.has_key?(:'event_add_item')
|
135
|
+
self.event_add_item = attributes[:'event_add_item']
|
136
|
+
end
|
137
|
+
|
122
138
|
if attributes.has_key?(:'event_conversation_closed')
|
123
139
|
self.event_conversation_closed = attributes[:'event_conversation_closed']
|
124
140
|
end
|
@@ -182,7 +198,7 @@ module UltracartClient
|
|
182
198
|
# Check to see if the all the properties in the model are valid
|
183
199
|
# @return true if the model is valid
|
184
200
|
def valid?
|
185
|
-
event_type_validator = EnumAttributeValidator.new('String', ['queue position', 'webchat start conversation', 'conversation closed', 'new conversation', 'new message', 'updated message', 'queue status update', 'rrweb', 'participant update', 'read message', 'typing'])
|
201
|
+
event_type_validator = EnumAttributeValidator.new('String', ['queue position', 'webchat start conversation', 'conversation closed', 'new conversation', 'new message', 'updated message', 'queue status update', 'rrweb', 'participant update', 'read message', 'typing', 'add coupon', 'add item'])
|
186
202
|
return false unless event_type_validator.valid?(@event_type)
|
187
203
|
type_validator = EnumAttributeValidator.new('String', ['message', 'event', 'ping', 'check queue position'])
|
188
204
|
return false unless type_validator.valid?(@type)
|
@@ -192,7 +208,7 @@ module UltracartClient
|
|
192
208
|
# Custom attribute writer method checking allowed values (enum).
|
193
209
|
# @param [Object] event_type Object to be assigned
|
194
210
|
def event_type=(event_type)
|
195
|
-
validator = EnumAttributeValidator.new('String', ['queue position', 'webchat start conversation', 'conversation closed', 'new conversation', 'new message', 'updated message', 'queue status update', 'rrweb', 'participant update', 'read message', 'typing'])
|
211
|
+
validator = EnumAttributeValidator.new('String', ['queue position', 'webchat start conversation', 'conversation closed', 'new conversation', 'new message', 'updated message', 'queue status update', 'rrweb', 'participant update', 'read message', 'typing', 'add coupon', 'add item'])
|
196
212
|
unless validator.valid?(event_type)
|
197
213
|
fail ArgumentError, 'invalid value for "event_type", must be one of #{validator.allowable_values}.'
|
198
214
|
end
|
@@ -215,6 +231,8 @@ module UltracartClient
|
|
215
231
|
return true if self.equal?(o)
|
216
232
|
self.class == o.class &&
|
217
233
|
conversation_uuid == o.conversation_uuid &&
|
234
|
+
event_add_coupon == o.event_add_coupon &&
|
235
|
+
event_add_item == o.event_add_item &&
|
218
236
|
event_conversation_closed == o.event_conversation_closed &&
|
219
237
|
event_new_conversation == o.event_new_conversation &&
|
220
238
|
event_new_message == o.event_new_message &&
|
@@ -239,7 +257,7 @@ module UltracartClient
|
|
239
257
|
# Calculates hash code according to all attributes.
|
240
258
|
# @return [Fixnum] Hash code
|
241
259
|
def hash
|
242
|
-
[conversation_uuid, event_conversation_closed, event_new_conversation, event_new_message, event_participant_update, event_queue_position, event_queue_status_update, event_read_message, event_rrweb, event_type, event_typing, event_updated_message, message, type].hash
|
260
|
+
[conversation_uuid, event_add_coupon, event_add_item, event_conversation_closed, event_new_conversation, event_new_message, event_participant_update, event_queue_position, event_queue_status_update, event_read_message, event_rrweb, event_type, event_typing, event_updated_message, message, type].hash
|
243
261
|
end
|
244
262
|
|
245
263
|
# Builds the object from hash
|
@@ -79,8 +79,8 @@ module UltracartClient
|
|
79
79
|
invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 100.')
|
80
80
|
end
|
81
81
|
|
82
|
-
if !@value.nil? && @value.to_s.length >
|
83
|
-
invalid_properties.push('invalid value for "value", the character length must be smaller than or equal to
|
82
|
+
if !@value.nil? && @value.to_s.length > 5000
|
83
|
+
invalid_properties.push('invalid value for "value", the character length must be smaller than or equal to 5000.')
|
84
84
|
end
|
85
85
|
|
86
86
|
invalid_properties
|
@@ -90,7 +90,7 @@ module UltracartClient
|
|
90
90
|
# @return true if the model is valid
|
91
91
|
def valid?
|
92
92
|
return false if !@name.nil? && @name.to_s.length > 100
|
93
|
-
return false if !@value.nil? && @value.to_s.length >
|
93
|
+
return false if !@value.nil? && @value.to_s.length > 5000
|
94
94
|
true
|
95
95
|
end
|
96
96
|
|
@@ -107,8 +107,8 @@ module UltracartClient
|
|
107
107
|
# Custom attribute writer method with validation
|
108
108
|
# @param [Object] value Value to be assigned
|
109
109
|
def value=(value)
|
110
|
-
if !value.nil? && value.to_s.length >
|
111
|
-
fail ArgumentError, 'invalid value for "value", the character length must be smaller than or equal to
|
110
|
+
if !value.nil? && value.to_s.length > 5000
|
111
|
+
fail ArgumentError, 'invalid value for "value", the character length must be smaller than or equal to 5000.'
|
112
112
|
end
|
113
113
|
|
114
114
|
@value = value
|
data/lib/ultracart_api.rb
CHANGED
@@ -137,6 +137,8 @@ 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_add_coupon'
|
141
|
+
require 'ultracart_api/models/conversation_event_add_item'
|
140
142
|
require 'ultracart_api/models/conversation_event_queue_position'
|
141
143
|
require 'ultracart_api/models/conversation_event_rr_web'
|
142
144
|
require 'ultracart_api/models/conversation_event_read_message'
|
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: 3.10.
|
4
|
+
version: 3.10.67
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- UltraCart
|
@@ -347,6 +347,8 @@ files:
|
|
347
347
|
- docs/ConversationAgentAuth.md
|
348
348
|
- docs/ConversationAgentAuthResponse.md
|
349
349
|
- docs/ConversationApi.md
|
350
|
+
- docs/ConversationEventAddCoupon.md
|
351
|
+
- docs/ConversationEventAddItem.md
|
350
352
|
- docs/ConversationEventQueuePosition.md
|
351
353
|
- docs/ConversationEventRRWeb.md
|
352
354
|
- docs/ConversationEventReadMessage.md
|
@@ -1067,6 +1069,8 @@ files:
|
|
1067
1069
|
- lib/ultracart_api/models/conversation.rb
|
1068
1070
|
- lib/ultracart_api/models/conversation_agent_auth.rb
|
1069
1071
|
- lib/ultracart_api/models/conversation_agent_auth_response.rb
|
1072
|
+
- lib/ultracart_api/models/conversation_event_add_coupon.rb
|
1073
|
+
- lib/ultracart_api/models/conversation_event_add_item.rb
|
1070
1074
|
- lib/ultracart_api/models/conversation_event_queue_position.rb
|
1071
1075
|
- lib/ultracart_api/models/conversation_event_read_message.rb
|
1072
1076
|
- lib/ultracart_api/models/conversation_event_rr_web.rb
|