ultracart_api 4.0.199 → 4.0.201
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +13 -4
- data/docs/ConversationAgentAuth.md +8 -0
- data/docs/CouponAmountOffItems.md +2 -0
- data/docs/CouponBuyOneGetOneLimit.md +2 -0
- data/docs/CouponDiscountItemWithItemPurchase.md +5 -1
- data/docs/CouponFreeItemWithItemPurchase.md +5 -1
- data/docs/CouponPercentOffItemsWithItemsPurchase.md +5 -1
- data/docs/EmailSmsOrder.md +24 -0
- data/docs/EmailSmsOrdersResponse.md +26 -0
- data/docs/EmailSmsStat.md +76 -0
- data/docs/EmailStatSmsSummaryRequest.md +20 -0
- data/docs/EmailStatSmsSummaryResponse.md +26 -0
- data/docs/PricingTier.md +2 -0
- data/docs/StorefrontApi.md +152 -0
- data/docs/Twilio.md +19 -1
- data/lib/ultracart_api/api/storefront_api.rb +156 -0
- data/lib/ultracart_api/models/conversation_agent_auth.rb +37 -1
- data/lib/ultracart_api/models/coupon_amount_off_items.rb +13 -1
- data/lib/ultracart_api/models/coupon_buy_one_get_one_limit.rb +13 -1
- data/lib/ultracart_api/models/coupon_discount_item_with_item_purchase.rb +28 -4
- data/lib/ultracart_api/models/coupon_free_item_with_item_purchase.rb +28 -4
- data/lib/ultracart_api/models/coupon_percent_off_items_with_items_purchase.rb +28 -4
- data/lib/ultracart_api/models/email_sms_order.rb +249 -0
- data/lib/ultracart_api/models/email_sms_orders_response.rb +258 -0
- data/lib/ultracart_api/models/email_sms_stat.rb +511 -0
- data/lib/ultracart_api/models/email_stat_sms_summary_request.rb +230 -0
- data/lib/ultracart_api/models/email_stat_sms_summary_response.rb +258 -0
- data/lib/ultracart_api/models/pricing_tier.rb +11 -1
- data/lib/ultracart_api/models/twilio.rb +85 -4
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +5 -0
- metadata +12 -2
@@ -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 EmailStatSmsSummaryRequest
|
18
|
+
attr_accessor :commseq_step_uuids
|
19
|
+
|
20
|
+
attr_accessor :days
|
21
|
+
|
22
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
23
|
+
def self.attribute_map
|
24
|
+
{
|
25
|
+
:'commseq_step_uuids' => :'commseq_step_uuids',
|
26
|
+
:'days' => :'days'
|
27
|
+
}
|
28
|
+
end
|
29
|
+
|
30
|
+
# Returns all the JSON keys this model knows about
|
31
|
+
def self.acceptable_attributes
|
32
|
+
attribute_map.values
|
33
|
+
end
|
34
|
+
|
35
|
+
# Attribute type mapping.
|
36
|
+
def self.openapi_types
|
37
|
+
{
|
38
|
+
:'commseq_step_uuids' => :'Array<String>',
|
39
|
+
:'days' => :'Integer'
|
40
|
+
}
|
41
|
+
end
|
42
|
+
|
43
|
+
# List of attributes with nullable: true
|
44
|
+
def self.openapi_nullable
|
45
|
+
Set.new([
|
46
|
+
])
|
47
|
+
end
|
48
|
+
|
49
|
+
# Initializes the object
|
50
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
51
|
+
def initialize(attributes = {})
|
52
|
+
if (!attributes.is_a?(Hash))
|
53
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::EmailStatSmsSummaryRequest` initialize method"
|
54
|
+
end
|
55
|
+
|
56
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
57
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
58
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::EmailStatSmsSummaryRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
60
|
+
end
|
61
|
+
h[k.to_sym] = v
|
62
|
+
}
|
63
|
+
|
64
|
+
if attributes.key?(:'commseq_step_uuids')
|
65
|
+
if (value = attributes[:'commseq_step_uuids']).is_a?(Array)
|
66
|
+
self.commseq_step_uuids = value
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
if attributes.key?(:'days')
|
71
|
+
self.days = attributes[:'days']
|
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
|
+
commseq_step_uuids == o.commseq_step_uuids &&
|
94
|
+
days == o.days
|
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
|
+
[commseq_step_uuids, days].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
|
@@ -0,0 +1,258 @@
|
|
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 EmailStatSmsSummaryResponse
|
18
|
+
attr_accessor :error
|
19
|
+
|
20
|
+
attr_accessor :metadata
|
21
|
+
|
22
|
+
attr_accessor :stats
|
23
|
+
|
24
|
+
# Indicates if API call was successful
|
25
|
+
attr_accessor :success
|
26
|
+
|
27
|
+
attr_accessor :warning
|
28
|
+
|
29
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
30
|
+
def self.attribute_map
|
31
|
+
{
|
32
|
+
:'error' => :'error',
|
33
|
+
:'metadata' => :'metadata',
|
34
|
+
:'stats' => :'stats',
|
35
|
+
:'success' => :'success',
|
36
|
+
:'warning' => :'warning'
|
37
|
+
}
|
38
|
+
end
|
39
|
+
|
40
|
+
# Returns all the JSON keys this model knows about
|
41
|
+
def self.acceptable_attributes
|
42
|
+
attribute_map.values
|
43
|
+
end
|
44
|
+
|
45
|
+
# Attribute type mapping.
|
46
|
+
def self.openapi_types
|
47
|
+
{
|
48
|
+
:'error' => :'Error',
|
49
|
+
:'metadata' => :'ResponseMetadata',
|
50
|
+
:'stats' => :'Array<EmailSmsStat>',
|
51
|
+
:'success' => :'Boolean',
|
52
|
+
:'warning' => :'Warning'
|
53
|
+
}
|
54
|
+
end
|
55
|
+
|
56
|
+
# List of attributes with nullable: true
|
57
|
+
def self.openapi_nullable
|
58
|
+
Set.new([
|
59
|
+
])
|
60
|
+
end
|
61
|
+
|
62
|
+
# Initializes the object
|
63
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
64
|
+
def initialize(attributes = {})
|
65
|
+
if (!attributes.is_a?(Hash))
|
66
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::EmailStatSmsSummaryResponse` initialize method"
|
67
|
+
end
|
68
|
+
|
69
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
70
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
71
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
72
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::EmailStatSmsSummaryResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
73
|
+
end
|
74
|
+
h[k.to_sym] = v
|
75
|
+
}
|
76
|
+
|
77
|
+
if attributes.key?(:'error')
|
78
|
+
self.error = attributes[:'error']
|
79
|
+
end
|
80
|
+
|
81
|
+
if attributes.key?(:'metadata')
|
82
|
+
self.metadata = attributes[:'metadata']
|
83
|
+
end
|
84
|
+
|
85
|
+
if attributes.key?(:'stats')
|
86
|
+
if (value = attributes[:'stats']).is_a?(Array)
|
87
|
+
self.stats = value
|
88
|
+
end
|
89
|
+
end
|
90
|
+
|
91
|
+
if attributes.key?(:'success')
|
92
|
+
self.success = attributes[:'success']
|
93
|
+
end
|
94
|
+
|
95
|
+
if attributes.key?(:'warning')
|
96
|
+
self.warning = attributes[:'warning']
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
100
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
101
|
+
# @return Array for valid properties with the reasons
|
102
|
+
def list_invalid_properties
|
103
|
+
invalid_properties = Array.new
|
104
|
+
invalid_properties
|
105
|
+
end
|
106
|
+
|
107
|
+
# Check to see if the all the properties in the model are valid
|
108
|
+
# @return true if the model is valid
|
109
|
+
def valid?
|
110
|
+
true
|
111
|
+
end
|
112
|
+
|
113
|
+
# Checks equality by comparing each attribute.
|
114
|
+
# @param [Object] Object to be compared
|
115
|
+
def ==(o)
|
116
|
+
return true if self.equal?(o)
|
117
|
+
self.class == o.class &&
|
118
|
+
error == o.error &&
|
119
|
+
metadata == o.metadata &&
|
120
|
+
stats == o.stats &&
|
121
|
+
success == o.success &&
|
122
|
+
warning == o.warning
|
123
|
+
end
|
124
|
+
|
125
|
+
# @see the `==` method
|
126
|
+
# @param [Object] Object to be compared
|
127
|
+
def eql?(o)
|
128
|
+
self == o
|
129
|
+
end
|
130
|
+
|
131
|
+
# Calculates hash code according to all attributes.
|
132
|
+
# @return [Integer] Hash code
|
133
|
+
def hash
|
134
|
+
[error, metadata, stats, success, warning].hash
|
135
|
+
end
|
136
|
+
|
137
|
+
# Builds the object from hash
|
138
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
139
|
+
# @return [Object] Returns the model itself
|
140
|
+
def self.build_from_hash(attributes)
|
141
|
+
new.build_from_hash(attributes)
|
142
|
+
end
|
143
|
+
|
144
|
+
# Builds the object from hash
|
145
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
146
|
+
# @return [Object] Returns the model itself
|
147
|
+
def build_from_hash(attributes)
|
148
|
+
return nil unless attributes.is_a?(Hash)
|
149
|
+
attributes = attributes.transform_keys(&:to_sym)
|
150
|
+
self.class.openapi_types.each_pair do |key, type|
|
151
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
152
|
+
self.send("#{key}=", nil)
|
153
|
+
elsif type =~ /\AArray<(.*)>/i
|
154
|
+
# check to ensure the input is an array given that the attribute
|
155
|
+
# is documented as an array but the input is not
|
156
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
157
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
158
|
+
end
|
159
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
160
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
161
|
+
end
|
162
|
+
end
|
163
|
+
|
164
|
+
self
|
165
|
+
end
|
166
|
+
|
167
|
+
# Deserializes the data based on type
|
168
|
+
# @param string type Data type
|
169
|
+
# @param string value Value to be deserialized
|
170
|
+
# @return [Object] Deserialized data
|
171
|
+
def _deserialize(type, value)
|
172
|
+
case type.to_sym
|
173
|
+
when :Time
|
174
|
+
Time.parse(value)
|
175
|
+
when :Date
|
176
|
+
Date.parse(value)
|
177
|
+
when :String
|
178
|
+
value.to_s
|
179
|
+
when :Integer
|
180
|
+
value.to_i
|
181
|
+
when :Float
|
182
|
+
value.to_f
|
183
|
+
when :Boolean
|
184
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
185
|
+
true
|
186
|
+
else
|
187
|
+
false
|
188
|
+
end
|
189
|
+
when :Object
|
190
|
+
# generic object (usually a Hash), return directly
|
191
|
+
value
|
192
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
193
|
+
inner_type = Regexp.last_match[:inner_type]
|
194
|
+
value.map { |v| _deserialize(inner_type, v) }
|
195
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
196
|
+
k_type = Regexp.last_match[:k_type]
|
197
|
+
v_type = Regexp.last_match[:v_type]
|
198
|
+
{}.tap do |hash|
|
199
|
+
value.each do |k, v|
|
200
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
201
|
+
end
|
202
|
+
end
|
203
|
+
else # model
|
204
|
+
# models (e.g. Pet) or oneOf
|
205
|
+
klass = UltracartClient.const_get(type)
|
206
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
207
|
+
end
|
208
|
+
end
|
209
|
+
|
210
|
+
# Returns the string representation of the object
|
211
|
+
# @return [String] String presentation of the object
|
212
|
+
def to_s
|
213
|
+
to_hash.to_s
|
214
|
+
end
|
215
|
+
|
216
|
+
# to_body is an alias to to_hash (backward compatibility)
|
217
|
+
# @return [Hash] Returns the object in the form of hash
|
218
|
+
def to_body
|
219
|
+
to_hash
|
220
|
+
end
|
221
|
+
|
222
|
+
# Returns the object in the form of hash
|
223
|
+
# @return [Hash] Returns the object in the form of hash
|
224
|
+
def to_hash
|
225
|
+
hash = {}
|
226
|
+
self.class.attribute_map.each_pair do |attr, param|
|
227
|
+
value = self.send(attr)
|
228
|
+
if value.nil?
|
229
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
230
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
231
|
+
end
|
232
|
+
|
233
|
+
hash[param] = _to_hash(value)
|
234
|
+
end
|
235
|
+
hash
|
236
|
+
end
|
237
|
+
|
238
|
+
# Outputs non-array value in the form of hash
|
239
|
+
# For object, use to_hash. Otherwise, just return the value
|
240
|
+
# @param [Object] value Any valid value
|
241
|
+
# @return [Hash] Returns the value in the form of hash
|
242
|
+
def _to_hash(value)
|
243
|
+
if value.is_a?(Array)
|
244
|
+
value.compact.map { |v| _to_hash(v) }
|
245
|
+
elsif value.is_a?(Hash)
|
246
|
+
{}.tap do |hash|
|
247
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
248
|
+
end
|
249
|
+
elsif value.respond_to? :to_hash
|
250
|
+
value.to_hash
|
251
|
+
else
|
252
|
+
value
|
253
|
+
end
|
254
|
+
end
|
255
|
+
|
256
|
+
end
|
257
|
+
|
258
|
+
end
|
@@ -35,6 +35,9 @@ module UltracartClient
|
|
35
35
|
# Auto approve purchase order
|
36
36
|
attr_accessor :auto_approve_purchase_order
|
37
37
|
|
38
|
+
# Any currency code specified on this pricing tier will force a shopping cart into that currency
|
39
|
+
attr_accessor :currency_code
|
40
|
+
|
38
41
|
# Default on wholesale signup
|
39
42
|
attr_accessor :default_on_wholesale_signup
|
40
43
|
|
@@ -122,6 +125,7 @@ module UltracartClient
|
|
122
125
|
:'approval_notification' => :'approval_notification',
|
123
126
|
:'auto_approve_cod' => :'auto_approve_cod',
|
124
127
|
:'auto_approve_purchase_order' => :'auto_approve_purchase_order',
|
128
|
+
:'currency_code' => :'currency_code',
|
125
129
|
:'default_on_wholesale_signup' => :'default_on_wholesale_signup',
|
126
130
|
:'default_percentage_discount' => :'default_percentage_discount',
|
127
131
|
:'default_shipping_method_oid' => :'default_shipping_method_oid',
|
@@ -166,6 +170,7 @@ module UltracartClient
|
|
166
170
|
:'approval_notification' => :'PricingTierNotification',
|
167
171
|
:'auto_approve_cod' => :'Boolean',
|
168
172
|
:'auto_approve_purchase_order' => :'Boolean',
|
173
|
+
:'currency_code' => :'String',
|
169
174
|
:'default_on_wholesale_signup' => :'Boolean',
|
170
175
|
:'default_percentage_discount' => :'Float',
|
171
176
|
:'default_shipping_method_oid' => :'Integer',
|
@@ -244,6 +249,10 @@ module UltracartClient
|
|
244
249
|
self.auto_approve_purchase_order = attributes[:'auto_approve_purchase_order']
|
245
250
|
end
|
246
251
|
|
252
|
+
if attributes.key?(:'currency_code')
|
253
|
+
self.currency_code = attributes[:'currency_code']
|
254
|
+
end
|
255
|
+
|
247
256
|
if attributes.key?(:'default_on_wholesale_signup')
|
248
257
|
self.default_on_wholesale_signup = attributes[:'default_on_wholesale_signup']
|
249
258
|
end
|
@@ -389,6 +398,7 @@ module UltracartClient
|
|
389
398
|
approval_notification == o.approval_notification &&
|
390
399
|
auto_approve_cod == o.auto_approve_cod &&
|
391
400
|
auto_approve_purchase_order == o.auto_approve_purchase_order &&
|
401
|
+
currency_code == o.currency_code &&
|
392
402
|
default_on_wholesale_signup == o.default_on_wholesale_signup &&
|
393
403
|
default_percentage_discount == o.default_percentage_discount &&
|
394
404
|
default_shipping_method_oid == o.default_shipping_method_oid &&
|
@@ -426,7 +436,7 @@ module UltracartClient
|
|
426
436
|
# Calculates hash code according to all attributes.
|
427
437
|
# @return [Integer] Hash code
|
428
438
|
def hash
|
429
|
-
[allow_3rd_party_billing, allow_cod, allow_purchase_order, allow_quote_request, approval_notification, auto_approve_cod, auto_approve_purchase_order, default_on_wholesale_signup, default_percentage_discount, default_shipping_method_oid, default_tier, display_on_wholesale_signup, exclude_from_free_promotion, exempt_loyalty_rewards, exempt_shipping_handling_charge, free_shipping, free_shipping_minimum, maximum_item_count, minimum_item_count, minimum_subtotal, name, no_coupons, no_free_shipping, no_realtime_charge, not_valid_when_coupon_present, pricing_tier_oid, realtime_percentage_discount, restrict_to_distribution_center_oid, signup_notification, suppress_buysafe, suppress_mailing_list, tax_exempt, track_separately].hash
|
439
|
+
[allow_3rd_party_billing, allow_cod, allow_purchase_order, allow_quote_request, approval_notification, auto_approve_cod, auto_approve_purchase_order, currency_code, default_on_wholesale_signup, default_percentage_discount, default_shipping_method_oid, default_tier, display_on_wholesale_signup, exclude_from_free_promotion, exempt_loyalty_rewards, exempt_shipping_handling_charge, free_shipping, free_shipping_minimum, maximum_item_count, minimum_item_count, minimum_subtotal, name, no_coupons, no_free_shipping, no_realtime_charge, not_valid_when_coupon_present, pricing_tier_oid, realtime_percentage_discount, restrict_to_distribution_center_oid, signup_notification, suppress_buysafe, suppress_mailing_list, tax_exempt, track_separately].hash
|
430
440
|
end
|
431
441
|
|
432
442
|
# Builds the object from hash
|
@@ -17,19 +17,46 @@ module UltracartClient
|
|
17
17
|
class Twilio
|
18
18
|
attr_accessor :account_sid
|
19
19
|
|
20
|
+
attr_accessor :api_key_id
|
21
|
+
|
22
|
+
attr_accessor :api_key_name
|
23
|
+
|
24
|
+
attr_accessor :api_key_secret
|
25
|
+
|
20
26
|
attr_accessor :auth_token
|
21
27
|
|
22
28
|
attr_accessor :esp_twilio_uuid
|
23
29
|
|
30
|
+
attr_accessor :inbound_twiml_app_sid
|
31
|
+
|
32
|
+
attr_accessor :outbound_twiml_app_sid
|
33
|
+
|
24
34
|
attr_accessor :phone_numbers
|
25
35
|
|
36
|
+
attr_accessor :private_key_pem
|
37
|
+
|
38
|
+
attr_accessor :public_key_pem
|
39
|
+
|
40
|
+
attr_accessor :public_key_sid
|
41
|
+
|
42
|
+
attr_accessor :twilio_workspace_sid
|
43
|
+
|
26
44
|
# Attribute mapping from ruby-style variable name to JSON key.
|
27
45
|
def self.attribute_map
|
28
46
|
{
|
29
47
|
:'account_sid' => :'account_sid',
|
48
|
+
:'api_key_id' => :'api_key_id',
|
49
|
+
:'api_key_name' => :'api_key_name',
|
50
|
+
:'api_key_secret' => :'api_key_secret',
|
30
51
|
:'auth_token' => :'auth_token',
|
31
52
|
:'esp_twilio_uuid' => :'esp_twilio_uuid',
|
32
|
-
:'
|
53
|
+
:'inbound_twiml_app_sid' => :'inbound_twiml_app_sid',
|
54
|
+
:'outbound_twiml_app_sid' => :'outbound_twiml_app_sid',
|
55
|
+
:'phone_numbers' => :'phone_numbers',
|
56
|
+
:'private_key_pem' => :'private_key_pem',
|
57
|
+
:'public_key_pem' => :'public_key_pem',
|
58
|
+
:'public_key_sid' => :'public_key_sid',
|
59
|
+
:'twilio_workspace_sid' => :'twilio_workspace_sid'
|
33
60
|
}
|
34
61
|
end
|
35
62
|
|
@@ -42,9 +69,18 @@ module UltracartClient
|
|
42
69
|
def self.openapi_types
|
43
70
|
{
|
44
71
|
:'account_sid' => :'String',
|
72
|
+
:'api_key_id' => :'String',
|
73
|
+
:'api_key_name' => :'String',
|
74
|
+
:'api_key_secret' => :'String',
|
45
75
|
:'auth_token' => :'String',
|
46
76
|
:'esp_twilio_uuid' => :'String',
|
47
|
-
:'
|
77
|
+
:'inbound_twiml_app_sid' => :'String',
|
78
|
+
:'outbound_twiml_app_sid' => :'String',
|
79
|
+
:'phone_numbers' => :'Array<String>',
|
80
|
+
:'private_key_pem' => :'String',
|
81
|
+
:'public_key_pem' => :'String',
|
82
|
+
:'public_key_sid' => :'String',
|
83
|
+
:'twilio_workspace_sid' => :'String'
|
48
84
|
}
|
49
85
|
end
|
50
86
|
|
@@ -73,6 +109,18 @@ module UltracartClient
|
|
73
109
|
self.account_sid = attributes[:'account_sid']
|
74
110
|
end
|
75
111
|
|
112
|
+
if attributes.key?(:'api_key_id')
|
113
|
+
self.api_key_id = attributes[:'api_key_id']
|
114
|
+
end
|
115
|
+
|
116
|
+
if attributes.key?(:'api_key_name')
|
117
|
+
self.api_key_name = attributes[:'api_key_name']
|
118
|
+
end
|
119
|
+
|
120
|
+
if attributes.key?(:'api_key_secret')
|
121
|
+
self.api_key_secret = attributes[:'api_key_secret']
|
122
|
+
end
|
123
|
+
|
76
124
|
if attributes.key?(:'auth_token')
|
77
125
|
self.auth_token = attributes[:'auth_token']
|
78
126
|
end
|
@@ -81,11 +129,35 @@ module UltracartClient
|
|
81
129
|
self.esp_twilio_uuid = attributes[:'esp_twilio_uuid']
|
82
130
|
end
|
83
131
|
|
132
|
+
if attributes.key?(:'inbound_twiml_app_sid')
|
133
|
+
self.inbound_twiml_app_sid = attributes[:'inbound_twiml_app_sid']
|
134
|
+
end
|
135
|
+
|
136
|
+
if attributes.key?(:'outbound_twiml_app_sid')
|
137
|
+
self.outbound_twiml_app_sid = attributes[:'outbound_twiml_app_sid']
|
138
|
+
end
|
139
|
+
|
84
140
|
if attributes.key?(:'phone_numbers')
|
85
141
|
if (value = attributes[:'phone_numbers']).is_a?(Array)
|
86
142
|
self.phone_numbers = value
|
87
143
|
end
|
88
144
|
end
|
145
|
+
|
146
|
+
if attributes.key?(:'private_key_pem')
|
147
|
+
self.private_key_pem = attributes[:'private_key_pem']
|
148
|
+
end
|
149
|
+
|
150
|
+
if attributes.key?(:'public_key_pem')
|
151
|
+
self.public_key_pem = attributes[:'public_key_pem']
|
152
|
+
end
|
153
|
+
|
154
|
+
if attributes.key?(:'public_key_sid')
|
155
|
+
self.public_key_sid = attributes[:'public_key_sid']
|
156
|
+
end
|
157
|
+
|
158
|
+
if attributes.key?(:'twilio_workspace_sid')
|
159
|
+
self.twilio_workspace_sid = attributes[:'twilio_workspace_sid']
|
160
|
+
end
|
89
161
|
end
|
90
162
|
|
91
163
|
# Show invalid properties with the reasons. Usually used together with valid?
|
@@ -107,9 +179,18 @@ module UltracartClient
|
|
107
179
|
return true if self.equal?(o)
|
108
180
|
self.class == o.class &&
|
109
181
|
account_sid == o.account_sid &&
|
182
|
+
api_key_id == o.api_key_id &&
|
183
|
+
api_key_name == o.api_key_name &&
|
184
|
+
api_key_secret == o.api_key_secret &&
|
110
185
|
auth_token == o.auth_token &&
|
111
186
|
esp_twilio_uuid == o.esp_twilio_uuid &&
|
112
|
-
|
187
|
+
inbound_twiml_app_sid == o.inbound_twiml_app_sid &&
|
188
|
+
outbound_twiml_app_sid == o.outbound_twiml_app_sid &&
|
189
|
+
phone_numbers == o.phone_numbers &&
|
190
|
+
private_key_pem == o.private_key_pem &&
|
191
|
+
public_key_pem == o.public_key_pem &&
|
192
|
+
public_key_sid == o.public_key_sid &&
|
193
|
+
twilio_workspace_sid == o.twilio_workspace_sid
|
113
194
|
end
|
114
195
|
|
115
196
|
# @see the `==` method
|
@@ -121,7 +202,7 @@ module UltracartClient
|
|
121
202
|
# Calculates hash code according to all attributes.
|
122
203
|
# @return [Integer] Hash code
|
123
204
|
def hash
|
124
|
-
[account_sid, auth_token, esp_twilio_uuid, phone_numbers].hash
|
205
|
+
[account_sid, api_key_id, api_key_name, api_key_secret, auth_token, esp_twilio_uuid, inbound_twiml_app_sid, outbound_twiml_app_sid, phone_numbers, private_key_pem, public_key_pem, public_key_sid, twilio_workspace_sid].hash
|
125
206
|
end
|
126
207
|
|
127
208
|
# Builds the object from hash
|