ultracart_api 4.0.208 → 4.0.210

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.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +19 -4
  3. data/docs/AutoOrder.md +2 -0
  4. data/docs/AutoOrderItem.md +4 -0
  5. data/docs/ConversationApi.md +575 -0
  6. data/docs/ConversationPbxVoicemailMessage.md +42 -0
  7. data/docs/ConversationPbxVoicemailMessageResponse.md +26 -0
  8. data/docs/ConversationPbxVoicemailMessageSummariesResponse.md +26 -0
  9. data/docs/ConversationPbxVoicemailMessageSummary.md +36 -0
  10. data/docs/ItemApi.md +73 -0
  11. data/docs/WorkflowTask.md +2 -2
  12. data/docs/WorkflowTasksRequest.md +4 -0
  13. data/lib/ultracart_api/api/conversation_api.rb +524 -0
  14. data/lib/ultracart_api/api/item_api.rb +75 -0
  15. data/lib/ultracart_api/models/auto_order.rb +11 -1
  16. data/lib/ultracart_api/models/auto_order_item.rb +21 -1
  17. data/lib/ultracart_api/models/conversation_pbx_phone_number_response.rb +1 -1
  18. data/lib/ultracart_api/models/conversation_pbx_phone_numbers_response.rb +1 -1
  19. data/lib/ultracart_api/models/conversation_pbx_time_based_response.rb +1 -1
  20. data/lib/ultracart_api/models/conversation_pbx_time_baseds_response.rb +1 -1
  21. data/lib/ultracart_api/models/conversation_pbx_time_range_response.rb +1 -1
  22. data/lib/ultracart_api/models/conversation_pbx_time_ranges_response.rb +1 -1
  23. data/lib/ultracart_api/models/conversation_pbx_voicemail_mailbox.rb +29 -5
  24. data/lib/ultracart_api/models/conversation_pbx_voicemail_mailbox_response.rb +1 -1
  25. data/lib/ultracart_api/models/conversation_pbx_voicemail_mailboxes_response.rb +1 -1
  26. data/lib/ultracart_api/models/conversation_pbx_voicemail_message.rb +374 -0
  27. data/lib/ultracart_api/models/conversation_pbx_voicemail_message_response.rb +256 -0
  28. data/lib/ultracart_api/models/conversation_pbx_voicemail_message_summaries_response.rb +258 -0
  29. data/lib/ultracart_api/models/conversation_pbx_voicemail_message_summary.rb +344 -0
  30. data/lib/ultracart_api/models/workflow_task.rb +2 -2
  31. data/lib/ultracart_api/models/workflow_tasks_request.rb +21 -1
  32. data/lib/ultracart_api/version.rb +1 -1
  33. data/lib/ultracart_api.rb +4 -0
  34. metadata +10 -2
@@ -0,0 +1,344 @@
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 ConversationPbxVoicemailMessageSummary
18
+ # Call SID
19
+ attr_accessor :call_sid
20
+
21
+ # Duration in seconds
22
+ attr_accessor :duration
23
+
24
+ # From phone number in E.164
25
+ attr_accessor :from
26
+
27
+ # From caller id (if available)
28
+ attr_accessor :from_caller_id
29
+
30
+ # True if the voicemail has been listened to in the user interface
31
+ attr_accessor :listened
32
+
33
+ # Merchant ID
34
+ attr_accessor :merchant_id
35
+
36
+ # Recording SID
37
+ attr_accessor :recording_sid
38
+
39
+ # Recording size in bytes
40
+ attr_accessor :recording_size_bytes
41
+
42
+ # Recording Status
43
+ attr_accessor :recording_status
44
+
45
+ # Voicemail date/time
46
+ attr_accessor :voicemail_dts
47
+
48
+ class EnumAttributeValidator
49
+ attr_reader :datatype
50
+ attr_reader :allowable_values
51
+
52
+ def initialize(datatype, allowable_values)
53
+ @allowable_values = allowable_values.map do |value|
54
+ case datatype.to_s
55
+ when /Integer/i
56
+ value.to_i
57
+ when /Float/i
58
+ value.to_f
59
+ else
60
+ value
61
+ end
62
+ end
63
+ end
64
+
65
+ def valid?(value)
66
+ !value || allowable_values.include?(value)
67
+ end
68
+ end
69
+
70
+ # Attribute mapping from ruby-style variable name to JSON key.
71
+ def self.attribute_map
72
+ {
73
+ :'call_sid' => :'call_sid',
74
+ :'duration' => :'duration',
75
+ :'from' => :'from',
76
+ :'from_caller_id' => :'from_caller_id',
77
+ :'listened' => :'listened',
78
+ :'merchant_id' => :'merchant_id',
79
+ :'recording_sid' => :'recording_sid',
80
+ :'recording_size_bytes' => :'recording_size_bytes',
81
+ :'recording_status' => :'recording_status',
82
+ :'voicemail_dts' => :'voicemail_dts'
83
+ }
84
+ end
85
+
86
+ # Returns all the JSON keys this model knows about
87
+ def self.acceptable_attributes
88
+ attribute_map.values
89
+ end
90
+
91
+ # Attribute type mapping.
92
+ def self.openapi_types
93
+ {
94
+ :'call_sid' => :'String',
95
+ :'duration' => :'Integer',
96
+ :'from' => :'String',
97
+ :'from_caller_id' => :'String',
98
+ :'listened' => :'Boolean',
99
+ :'merchant_id' => :'String',
100
+ :'recording_sid' => :'String',
101
+ :'recording_size_bytes' => :'Integer',
102
+ :'recording_status' => :'String',
103
+ :'voicemail_dts' => :'String'
104
+ }
105
+ end
106
+
107
+ # List of attributes with nullable: true
108
+ def self.openapi_nullable
109
+ Set.new([
110
+ ])
111
+ end
112
+
113
+ # Initializes the object
114
+ # @param [Hash] attributes Model attributes in the form of hash
115
+ def initialize(attributes = {})
116
+ if (!attributes.is_a?(Hash))
117
+ fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::ConversationPbxVoicemailMessageSummary` initialize method"
118
+ end
119
+
120
+ # check to see if the attribute exists and convert string to symbol for hash key
121
+ attributes = attributes.each_with_object({}) { |(k, v), h|
122
+ if (!self.class.attribute_map.key?(k.to_sym))
123
+ fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::ConversationPbxVoicemailMessageSummary`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
124
+ end
125
+ h[k.to_sym] = v
126
+ }
127
+
128
+ if attributes.key?(:'call_sid')
129
+ self.call_sid = attributes[:'call_sid']
130
+ end
131
+
132
+ if attributes.key?(:'duration')
133
+ self.duration = attributes[:'duration']
134
+ end
135
+
136
+ if attributes.key?(:'from')
137
+ self.from = attributes[:'from']
138
+ end
139
+
140
+ if attributes.key?(:'from_caller_id')
141
+ self.from_caller_id = attributes[:'from_caller_id']
142
+ end
143
+
144
+ if attributes.key?(:'listened')
145
+ self.listened = attributes[:'listened']
146
+ end
147
+
148
+ if attributes.key?(:'merchant_id')
149
+ self.merchant_id = attributes[:'merchant_id']
150
+ end
151
+
152
+ if attributes.key?(:'recording_sid')
153
+ self.recording_sid = attributes[:'recording_sid']
154
+ end
155
+
156
+ if attributes.key?(:'recording_size_bytes')
157
+ self.recording_size_bytes = attributes[:'recording_size_bytes']
158
+ end
159
+
160
+ if attributes.key?(:'recording_status')
161
+ self.recording_status = attributes[:'recording_status']
162
+ end
163
+
164
+ if attributes.key?(:'voicemail_dts')
165
+ self.voicemail_dts = attributes[:'voicemail_dts']
166
+ end
167
+ end
168
+
169
+ # Show invalid properties with the reasons. Usually used together with valid?
170
+ # @return Array for valid properties with the reasons
171
+ def list_invalid_properties
172
+ invalid_properties = Array.new
173
+ invalid_properties
174
+ end
175
+
176
+ # Check to see if the all the properties in the model are valid
177
+ # @return true if the model is valid
178
+ def valid?
179
+ recording_status_validator = EnumAttributeValidator.new('String', ["completed"])
180
+ return false unless recording_status_validator.valid?(@recording_status)
181
+ true
182
+ end
183
+
184
+ # Custom attribute writer method checking allowed values (enum).
185
+ # @param [Object] recording_status Object to be assigned
186
+ def recording_status=(recording_status)
187
+ validator = EnumAttributeValidator.new('String', ["completed"])
188
+ unless validator.valid?(recording_status)
189
+ fail ArgumentError, "invalid value for \"recording_status\", must be one of #{validator.allowable_values}."
190
+ end
191
+ @recording_status = recording_status
192
+ end
193
+
194
+ # Checks equality by comparing each attribute.
195
+ # @param [Object] Object to be compared
196
+ def ==(o)
197
+ return true if self.equal?(o)
198
+ self.class == o.class &&
199
+ call_sid == o.call_sid &&
200
+ duration == o.duration &&
201
+ from == o.from &&
202
+ from_caller_id == o.from_caller_id &&
203
+ listened == o.listened &&
204
+ merchant_id == o.merchant_id &&
205
+ recording_sid == o.recording_sid &&
206
+ recording_size_bytes == o.recording_size_bytes &&
207
+ recording_status == o.recording_status &&
208
+ voicemail_dts == o.voicemail_dts
209
+ end
210
+
211
+ # @see the `==` method
212
+ # @param [Object] Object to be compared
213
+ def eql?(o)
214
+ self == o
215
+ end
216
+
217
+ # Calculates hash code according to all attributes.
218
+ # @return [Integer] Hash code
219
+ def hash
220
+ [call_sid, duration, from, from_caller_id, listened, merchant_id, recording_sid, recording_size_bytes, recording_status, voicemail_dts].hash
221
+ end
222
+
223
+ # Builds the object from hash
224
+ # @param [Hash] attributes Model attributes in the form of hash
225
+ # @return [Object] Returns the model itself
226
+ def self.build_from_hash(attributes)
227
+ new.build_from_hash(attributes)
228
+ end
229
+
230
+ # Builds the object from hash
231
+ # @param [Hash] attributes Model attributes in the form of hash
232
+ # @return [Object] Returns the model itself
233
+ def build_from_hash(attributes)
234
+ return nil unless attributes.is_a?(Hash)
235
+ attributes = attributes.transform_keys(&:to_sym)
236
+ self.class.openapi_types.each_pair do |key, type|
237
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
238
+ self.send("#{key}=", nil)
239
+ elsif type =~ /\AArray<(.*)>/i
240
+ # check to ensure the input is an array given that the attribute
241
+ # is documented as an array but the input is not
242
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
243
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
244
+ end
245
+ elsif !attributes[self.class.attribute_map[key]].nil?
246
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
247
+ end
248
+ end
249
+
250
+ self
251
+ end
252
+
253
+ # Deserializes the data based on type
254
+ # @param string type Data type
255
+ # @param string value Value to be deserialized
256
+ # @return [Object] Deserialized data
257
+ def _deserialize(type, value)
258
+ case type.to_sym
259
+ when :Time
260
+ Time.parse(value)
261
+ when :Date
262
+ Date.parse(value)
263
+ when :String
264
+ value.to_s
265
+ when :Integer
266
+ value.to_i
267
+ when :Float
268
+ value.to_f
269
+ when :Boolean
270
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
271
+ true
272
+ else
273
+ false
274
+ end
275
+ when :Object
276
+ # generic object (usually a Hash), return directly
277
+ value
278
+ when /\AArray<(?<inner_type>.+)>\z/
279
+ inner_type = Regexp.last_match[:inner_type]
280
+ value.map { |v| _deserialize(inner_type, v) }
281
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
282
+ k_type = Regexp.last_match[:k_type]
283
+ v_type = Regexp.last_match[:v_type]
284
+ {}.tap do |hash|
285
+ value.each do |k, v|
286
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
287
+ end
288
+ end
289
+ else # model
290
+ # models (e.g. Pet) or oneOf
291
+ klass = UltracartClient.const_get(type)
292
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
293
+ end
294
+ end
295
+
296
+ # Returns the string representation of the object
297
+ # @return [String] String presentation of the object
298
+ def to_s
299
+ to_hash.to_s
300
+ end
301
+
302
+ # to_body is an alias to to_hash (backward compatibility)
303
+ # @return [Hash] Returns the object in the form of hash
304
+ def to_body
305
+ to_hash
306
+ end
307
+
308
+ # Returns the object in the form of hash
309
+ # @return [Hash] Returns the object in the form of hash
310
+ def to_hash
311
+ hash = {}
312
+ self.class.attribute_map.each_pair do |attr, param|
313
+ value = self.send(attr)
314
+ if value.nil?
315
+ is_nullable = self.class.openapi_nullable.include?(attr)
316
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
317
+ end
318
+
319
+ hash[param] = _to_hash(value)
320
+ end
321
+ hash
322
+ end
323
+
324
+ # Outputs non-array value in the form of hash
325
+ # For object, use to_hash. Otherwise, just return the value
326
+ # @param [Object] value Any valid value
327
+ # @return [Hash] Returns the value in the form of hash
328
+ def _to_hash(value)
329
+ if value.is_a?(Array)
330
+ value.compact.map { |v| _to_hash(v) }
331
+ elsif value.is_a?(Hash)
332
+ {}.tap do |hash|
333
+ value.each { |k, v| hash[k] = _to_hash(v) }
334
+ end
335
+ elsif value.respond_to? :to_hash
336
+ value.to_hash
337
+ else
338
+ value
339
+ end
340
+ end
341
+
342
+ end
343
+
344
+ end
@@ -50,7 +50,7 @@ module UltracartClient
50
50
  # Date/time that the workflow task will expire and be closed. This is set by system generated tasks.
51
51
  attr_accessor :expiration_dts
52
52
 
53
- # Global task numer
53
+ # Global task number
54
54
  attr_accessor :global_task_number
55
55
 
56
56
  # Array of history records for the task
@@ -71,7 +71,7 @@ module UltracartClient
71
71
  # Object ID
72
72
  attr_accessor :object_id
73
73
 
74
- # Object specific task numer
74
+ # Object specific task number
75
75
  attr_accessor :object_task_number
76
76
 
77
77
  # Object Type
@@ -15,12 +15,18 @@ require 'time'
15
15
 
16
16
  module UltracartClient
17
17
  class WorkflowTasksRequest
18
+ # Assigned to group
19
+ attr_accessor :assigned_to_group
20
+
18
21
  # Assigned to group ID
19
22
  attr_accessor :assigned_to_group_id
20
23
 
21
24
  # Tasks are assigned to me either by direct user id or a group that the user is a member of
22
25
  attr_accessor :assigned_to_me
23
26
 
27
+ # Assigned to user
28
+ attr_accessor :assigned_to_user
29
+
24
30
  # Assigned to user ID
25
31
  attr_accessor :assigned_to_user_id
26
32
 
@@ -93,8 +99,10 @@ module UltracartClient
93
99
  # Attribute mapping from ruby-style variable name to JSON key.
94
100
  def self.attribute_map
95
101
  {
102
+ :'assigned_to_group' => :'assigned_to_group',
96
103
  :'assigned_to_group_id' => :'assigned_to_group_id',
97
104
  :'assigned_to_me' => :'assigned_to_me',
105
+ :'assigned_to_user' => :'assigned_to_user',
98
106
  :'assigned_to_user_id' => :'assigned_to_user_id',
99
107
  :'created_by' => :'created_by',
100
108
  :'created_dts_begin' => :'created_dts_begin',
@@ -122,8 +130,10 @@ module UltracartClient
122
130
  # Attribute type mapping.
123
131
  def self.openapi_types
124
132
  {
133
+ :'assigned_to_group' => :'String',
125
134
  :'assigned_to_group_id' => :'Integer',
126
135
  :'assigned_to_me' => :'Boolean',
136
+ :'assigned_to_user' => :'String',
127
137
  :'assigned_to_user_id' => :'Integer',
128
138
  :'created_by' => :'WorkflowUser',
129
139
  :'created_dts_begin' => :'String',
@@ -164,6 +174,10 @@ module UltracartClient
164
174
  h[k.to_sym] = v
165
175
  }
166
176
 
177
+ if attributes.key?(:'assigned_to_group')
178
+ self.assigned_to_group = attributes[:'assigned_to_group']
179
+ end
180
+
167
181
  if attributes.key?(:'assigned_to_group_id')
168
182
  self.assigned_to_group_id = attributes[:'assigned_to_group_id']
169
183
  end
@@ -172,6 +186,10 @@ module UltracartClient
172
186
  self.assigned_to_me = attributes[:'assigned_to_me']
173
187
  end
174
188
 
189
+ if attributes.key?(:'assigned_to_user')
190
+ self.assigned_to_user = attributes[:'assigned_to_user']
191
+ end
192
+
175
193
  if attributes.key?(:'assigned_to_user_id')
176
194
  self.assigned_to_user_id = attributes[:'assigned_to_user_id']
177
195
  end
@@ -293,8 +311,10 @@ module UltracartClient
293
311
  def ==(o)
294
312
  return true if self.equal?(o)
295
313
  self.class == o.class &&
314
+ assigned_to_group == o.assigned_to_group &&
296
315
  assigned_to_group_id == o.assigned_to_group_id &&
297
316
  assigned_to_me == o.assigned_to_me &&
317
+ assigned_to_user == o.assigned_to_user &&
298
318
  assigned_to_user_id == o.assigned_to_user_id &&
299
319
  created_by == o.created_by &&
300
320
  created_dts_begin == o.created_dts_begin &&
@@ -322,7 +342,7 @@ module UltracartClient
322
342
  # Calculates hash code according to all attributes.
323
343
  # @return [Integer] Hash code
324
344
  def hash
325
- [assigned_to_group_id, assigned_to_me, assigned_to_user_id, created_by, created_dts_begin, created_dts_end, delay_until_dts_begin, delay_until_dts_end, due_dts_begin, due_dts_end, last_update_dts_begin, last_update_dts_end, object_email, object_type, priority, status, tags, unassigned].hash
345
+ [assigned_to_group, assigned_to_group_id, assigned_to_me, assigned_to_user, assigned_to_user_id, created_by, created_dts_begin, created_dts_end, delay_until_dts_begin, delay_until_dts_end, due_dts_begin, due_dts_end, last_update_dts_begin, last_update_dts_end, object_email, object_type, priority, status, tags, unassigned].hash
326
346
  end
327
347
 
328
348
  # Builds the object from hash
@@ -11,5 +11,5 @@ OpenAPI Generator version: 6.0.1-SNAPSHOT
11
11
  =end
12
12
 
13
13
  module UltracartClient
14
- VERSION = '4.0.208'
14
+ VERSION = '4.0.210'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -216,6 +216,10 @@ require 'ultracart_api/models/conversation_pbx_time_ranges_response'
216
216
  require 'ultracart_api/models/conversation_pbx_voicemail_mailbox'
217
217
  require 'ultracart_api/models/conversation_pbx_voicemail_mailbox_response'
218
218
  require 'ultracart_api/models/conversation_pbx_voicemail_mailboxes_response'
219
+ require 'ultracart_api/models/conversation_pbx_voicemail_message'
220
+ require 'ultracart_api/models/conversation_pbx_voicemail_message_response'
221
+ require 'ultracart_api/models/conversation_pbx_voicemail_message_summaries_response'
222
+ require 'ultracart_api/models/conversation_pbx_voicemail_message_summary'
219
223
  require 'ultracart_api/models/conversation_permissions'
220
224
  require 'ultracart_api/models/conversation_permissions_response'
221
225
  require 'ultracart_api/models/conversation_response'
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.208
4
+ version: 4.0.210
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-03-26 00:00:00.000000000 Z
11
+ date: 2024-04-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -266,6 +266,10 @@ files:
266
266
  - docs/ConversationPbxVoicemailMailbox.md
267
267
  - docs/ConversationPbxVoicemailMailboxResponse.md
268
268
  - docs/ConversationPbxVoicemailMailboxesResponse.md
269
+ - docs/ConversationPbxVoicemailMessage.md
270
+ - docs/ConversationPbxVoicemailMessageResponse.md
271
+ - docs/ConversationPbxVoicemailMessageSummariesResponse.md
272
+ - docs/ConversationPbxVoicemailMessageSummary.md
269
273
  - docs/ConversationPermissions.md
270
274
  - docs/ConversationPermissionsResponse.md
271
275
  - docs/ConversationResponse.md
@@ -1147,6 +1151,10 @@ files:
1147
1151
  - lib/ultracart_api/models/conversation_pbx_voicemail_mailbox.rb
1148
1152
  - lib/ultracart_api/models/conversation_pbx_voicemail_mailbox_response.rb
1149
1153
  - lib/ultracart_api/models/conversation_pbx_voicemail_mailboxes_response.rb
1154
+ - lib/ultracart_api/models/conversation_pbx_voicemail_message.rb
1155
+ - lib/ultracart_api/models/conversation_pbx_voicemail_message_response.rb
1156
+ - lib/ultracart_api/models/conversation_pbx_voicemail_message_summaries_response.rb
1157
+ - lib/ultracart_api/models/conversation_pbx_voicemail_message_summary.rb
1150
1158
  - lib/ultracart_api/models/conversation_permissions.rb
1151
1159
  - lib/ultracart_api/models/conversation_permissions_response.rb
1152
1160
  - lib/ultracart_api/models/conversation_response.rb