ultracart_api 3.10.18 → 3.10.21

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.
@@ -0,0 +1,412 @@
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 'addressable/uri'
14
+
15
+ module UltracartClient
16
+ class ConversationApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::ConversationApi.new(api_client)
33
+ end
34
+
35
+ # Get agent websocket authorization
36
+ # Retrieve a JWT to authorize an agent to make a websocket connection.
37
+ # @param [Hash] opts the optional parameters
38
+ # @return [ConversationAgentAuthResponse]
39
+ def get_agent_websocket_authorization(opts = {})
40
+ data, _status_code, _headers = get_agent_websocket_authorization_with_http_info(opts)
41
+ data
42
+ end
43
+
44
+ # Get agent websocket authorization
45
+ # Retrieve a JWT to authorize an agent to make a websocket connection.
46
+ # @param [Hash] opts the optional parameters
47
+ # @return [Array<(ConversationAgentAuthResponse, Fixnum, Hash)>] ConversationAgentAuthResponse data, response status code and response headers
48
+ def get_agent_websocket_authorization_with_http_info(opts = {})
49
+ if @api_client.config.debugging
50
+ @api_client.config.logger.debug 'Calling API: ConversationApi.get_agent_websocket_authorization ...'
51
+ end
52
+ # resource path
53
+ local_var_path = '/conversation/agent/auth'
54
+
55
+ # query parameters
56
+ query_params = {}
57
+
58
+ # header parameters
59
+ header_params = {}
60
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
61
+ # HTTP header 'Accept' (if needed)
62
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
63
+ # HTTP header 'Content-Type'
64
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
65
+
66
+ # form parameters
67
+ form_params = {}
68
+
69
+ # http body (model)
70
+ post_body = nil
71
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
72
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
73
+ :header_params => header_params,
74
+ :query_params => query_params,
75
+ :form_params => form_params,
76
+ :body => post_body,
77
+ :auth_names => auth_names,
78
+ :return_type => 'ConversationAgentAuthResponse')
79
+ if @api_client.config.debugging
80
+ @api_client.config.logger.debug "API called: ConversationApi#get_agent_websocket_authorization\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
81
+ end
82
+ return data, status_code, headers
83
+ end
84
+ # Retrieve a conversation
85
+ # Retrieve a conversation including the participants and messages
86
+ # @param conversation_uuid
87
+ # @param [Hash] opts the optional parameters
88
+ # @return [Conversation]
89
+ def get_conversation(conversation_uuid, opts = {})
90
+ data, _status_code, _headers = get_conversation_with_http_info(conversation_uuid, opts)
91
+ data
92
+ end
93
+
94
+ # Retrieve a conversation
95
+ # Retrieve a conversation including the participants and messages
96
+ # @param conversation_uuid
97
+ # @param [Hash] opts the optional parameters
98
+ # @return [Array<(Conversation, Fixnum, Hash)>] Conversation data, response status code and response headers
99
+ def get_conversation_with_http_info(conversation_uuid, opts = {})
100
+ if @api_client.config.debugging
101
+ @api_client.config.logger.debug 'Calling API: ConversationApi.get_conversation ...'
102
+ end
103
+ # verify the required parameter 'conversation_uuid' is set
104
+ if @api_client.config.client_side_validation && conversation_uuid.nil?
105
+ fail ArgumentError, "Missing the required parameter 'conversation_uuid' when calling ConversationApi.get_conversation"
106
+ end
107
+ # resource path
108
+ local_var_path = '/conversation/conversations/{conversation_uuid}'.sub('{' + 'conversation_uuid' + '}', conversation_uuid.to_s)
109
+
110
+ # query parameters
111
+ query_params = {}
112
+
113
+ # header parameters
114
+ header_params = {}
115
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
116
+ # HTTP header 'Accept' (if needed)
117
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
118
+ # HTTP header 'Content-Type'
119
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
120
+
121
+ # form parameters
122
+ form_params = {}
123
+
124
+ # http body (model)
125
+ post_body = nil
126
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
127
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
128
+ :header_params => header_params,
129
+ :query_params => query_params,
130
+ :form_params => form_params,
131
+ :body => post_body,
132
+ :auth_names => auth_names,
133
+ :return_type => 'Conversation')
134
+ if @api_client.config.debugging
135
+ @api_client.config.logger.debug "API called: ConversationApi#get_conversation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
136
+ end
137
+ return data, status_code, headers
138
+ end
139
+ # Get a presigned conersation multimedia upload URL
140
+ # Get a presigned conersation multimedia upload URL
141
+ # @param extension
142
+ # @param [Hash] opts the optional parameters
143
+ # @return [nil]
144
+ def get_conversation_multimedia_upload_url(extension, opts = {})
145
+ get_conversation_multimedia_upload_url_with_http_info(extension, opts)
146
+ nil
147
+ end
148
+
149
+ # Get a presigned conersation multimedia upload URL
150
+ # Get a presigned conersation multimedia upload URL
151
+ # @param extension
152
+ # @param [Hash] opts the optional parameters
153
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
154
+ def get_conversation_multimedia_upload_url_with_http_info(extension, opts = {})
155
+ if @api_client.config.debugging
156
+ @api_client.config.logger.debug 'Calling API: ConversationApi.get_conversation_multimedia_upload_url ...'
157
+ end
158
+ # verify the required parameter 'extension' is set
159
+ if @api_client.config.client_side_validation && extension.nil?
160
+ fail ArgumentError, "Missing the required parameter 'extension' when calling ConversationApi.get_conversation_multimedia_upload_url"
161
+ end
162
+ # resource path
163
+ local_var_path = '/conversation/upload_url/{extension}'.sub('{' + 'extension' + '}', extension.to_s)
164
+
165
+ # query parameters
166
+ query_params = {}
167
+
168
+ # header parameters
169
+ header_params = {}
170
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
171
+ # HTTP header 'Accept' (if needed)
172
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
173
+ # HTTP header 'Content-Type'
174
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
175
+
176
+ # form parameters
177
+ form_params = {}
178
+
179
+ # http body (model)
180
+ post_body = nil
181
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
182
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
183
+ :header_params => header_params,
184
+ :query_params => query_params,
185
+ :form_params => form_params,
186
+ :body => post_body,
187
+ :auth_names => auth_names)
188
+ if @api_client.config.debugging
189
+ @api_client.config.logger.debug "API called: ConversationApi#get_conversation_multimedia_upload_url\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
190
+ end
191
+ return data, status_code, headers
192
+ end
193
+ # Retrieve a list of conversation summaries newest to oldest
194
+ # Retrieve a list of conversation summaries that are ordered newest to oldest, include the most recent message and whether its been read.
195
+ # @param [Hash] opts the optional parameters
196
+ # @option opts [Integer] :_limit The maximum number of records to return on this one API call. (Max 200) (default to 100)
197
+ # @option opts [Integer] :_offset Pagination of the record set. Offset is a zero based index. (default to 0)
198
+ # @return [ConversationsResponse]
199
+ def get_conversations(opts = {})
200
+ data, _status_code, _headers = get_conversations_with_http_info(opts)
201
+ data
202
+ end
203
+
204
+ # Retrieve a list of conversation summaries newest to oldest
205
+ # Retrieve a list of conversation summaries that are ordered newest to oldest, include the most recent message and whether its been read.
206
+ # @param [Hash] opts the optional parameters
207
+ # @option opts [Integer] :_limit The maximum number of records to return on this one API call. (Max 200)
208
+ # @option opts [Integer] :_offset Pagination of the record set. Offset is a zero based index.
209
+ # @return [Array<(ConversationsResponse, Fixnum, Hash)>] ConversationsResponse data, response status code and response headers
210
+ def get_conversations_with_http_info(opts = {})
211
+ if @api_client.config.debugging
212
+ @api_client.config.logger.debug 'Calling API: ConversationApi.get_conversations ...'
213
+ end
214
+ # resource path
215
+ local_var_path = '/conversation/conversations'
216
+
217
+ # query parameters
218
+ query_params = {}
219
+ query_params[:'_limit'] = opts[:'_limit'] if !opts[:'_limit'].nil?
220
+ query_params[:'_offset'] = opts[:'_offset'] if !opts[:'_offset'].nil?
221
+
222
+ # header parameters
223
+ header_params = {}
224
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
225
+ # HTTP header 'Accept' (if needed)
226
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
227
+ # HTTP header 'Content-Type'
228
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
229
+
230
+ # form parameters
231
+ form_params = {}
232
+
233
+ # http body (model)
234
+ post_body = nil
235
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
236
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
237
+ :header_params => header_params,
238
+ :query_params => query_params,
239
+ :form_params => form_params,
240
+ :body => post_body,
241
+ :auth_names => auth_names,
242
+ :return_type => 'ConversationsResponse')
243
+ if @api_client.config.debugging
244
+ @api_client.config.logger.debug "API called: ConversationApi#get_conversations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
245
+ end
246
+ return data, status_code, headers
247
+ end
248
+ # Join a conversation
249
+ # Join a conversation
250
+ # @param conversation_uuid
251
+ # @param [Hash] opts the optional parameters
252
+ # @return [nil]
253
+ def join_conversation(conversation_uuid, opts = {})
254
+ join_conversation_with_http_info(conversation_uuid, opts)
255
+ nil
256
+ end
257
+
258
+ # Join a conversation
259
+ # Join a conversation
260
+ # @param conversation_uuid
261
+ # @param [Hash] opts the optional parameters
262
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
263
+ def join_conversation_with_http_info(conversation_uuid, opts = {})
264
+ if @api_client.config.debugging
265
+ @api_client.config.logger.debug 'Calling API: ConversationApi.join_conversation ...'
266
+ end
267
+ # verify the required parameter 'conversation_uuid' is set
268
+ if @api_client.config.client_side_validation && conversation_uuid.nil?
269
+ fail ArgumentError, "Missing the required parameter 'conversation_uuid' when calling ConversationApi.join_conversation"
270
+ end
271
+ # resource path
272
+ local_var_path = '/conversation/conversations/{conversation_uuid}/join'.sub('{' + 'conversation_uuid' + '}', conversation_uuid.to_s)
273
+
274
+ # query parameters
275
+ query_params = {}
276
+
277
+ # header parameters
278
+ header_params = {}
279
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
280
+ # HTTP header 'Accept' (if needed)
281
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
282
+ # HTTP header 'Content-Type'
283
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
284
+
285
+ # form parameters
286
+ form_params = {}
287
+
288
+ # http body (model)
289
+ post_body = nil
290
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
291
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
292
+ :header_params => header_params,
293
+ :query_params => query_params,
294
+ :form_params => form_params,
295
+ :body => post_body,
296
+ :auth_names => auth_names)
297
+ if @api_client.config.debugging
298
+ @api_client.config.logger.debug "API called: ConversationApi#join_conversation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
299
+ end
300
+ return data, status_code, headers
301
+ end
302
+ # Leave a conversation
303
+ # Leave a conversation
304
+ # @param conversation_uuid
305
+ # @param [Hash] opts the optional parameters
306
+ # @return [nil]
307
+ def leave_conversation(conversation_uuid, opts = {})
308
+ leave_conversation_with_http_info(conversation_uuid, opts)
309
+ nil
310
+ end
311
+
312
+ # Leave a conversation
313
+ # Leave a conversation
314
+ # @param conversation_uuid
315
+ # @param [Hash] opts the optional parameters
316
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
317
+ def leave_conversation_with_http_info(conversation_uuid, opts = {})
318
+ if @api_client.config.debugging
319
+ @api_client.config.logger.debug 'Calling API: ConversationApi.leave_conversation ...'
320
+ end
321
+ # verify the required parameter 'conversation_uuid' is set
322
+ if @api_client.config.client_side_validation && conversation_uuid.nil?
323
+ fail ArgumentError, "Missing the required parameter 'conversation_uuid' when calling ConversationApi.leave_conversation"
324
+ end
325
+ # resource path
326
+ local_var_path = '/conversation/conversations/{conversation_uuid}/leave'.sub('{' + 'conversation_uuid' + '}', conversation_uuid.to_s)
327
+
328
+ # query parameters
329
+ query_params = {}
330
+
331
+ # header parameters
332
+ header_params = {}
333
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
334
+ # HTTP header 'Accept' (if needed)
335
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
336
+ # HTTP header 'Content-Type'
337
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
338
+
339
+ # form parameters
340
+ form_params = {}
341
+
342
+ # http body (model)
343
+ post_body = nil
344
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
345
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
346
+ :header_params => header_params,
347
+ :query_params => query_params,
348
+ :form_params => form_params,
349
+ :body => post_body,
350
+ :auth_names => auth_names)
351
+ if @api_client.config.debugging
352
+ @api_client.config.logger.debug "API called: ConversationApi#leave_conversation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
353
+ end
354
+ return data, status_code, headers
355
+ end
356
+ # Start a conversation
357
+ # Start a new conversation
358
+ # @param start_request Start request
359
+ # @param [Hash] opts the optional parameters
360
+ # @return [ConversationStartResponse]
361
+ def start_conversation(start_request, opts = {})
362
+ data, _status_code, _headers = start_conversation_with_http_info(start_request, opts)
363
+ data
364
+ end
365
+
366
+ # Start a conversation
367
+ # Start a new conversation
368
+ # @param start_request Start request
369
+ # @param [Hash] opts the optional parameters
370
+ # @return [Array<(ConversationStartResponse, Fixnum, Hash)>] ConversationStartResponse data, response status code and response headers
371
+ def start_conversation_with_http_info(start_request, opts = {})
372
+ if @api_client.config.debugging
373
+ @api_client.config.logger.debug 'Calling API: ConversationApi.start_conversation ...'
374
+ end
375
+ # verify the required parameter 'start_request' is set
376
+ if @api_client.config.client_side_validation && start_request.nil?
377
+ fail ArgumentError, "Missing the required parameter 'start_request' when calling ConversationApi.start_conversation"
378
+ end
379
+ # resource path
380
+ local_var_path = '/conversation/conversations'
381
+
382
+ # query parameters
383
+ query_params = {}
384
+
385
+ # header parameters
386
+ header_params = {}
387
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
388
+ # HTTP header 'Accept' (if needed)
389
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
390
+ # HTTP header 'Content-Type'
391
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
392
+
393
+ # form parameters
394
+ form_params = {}
395
+
396
+ # http body (model)
397
+ post_body = @api_client.object_to_http_body(start_request)
398
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
399
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
400
+ :header_params => header_params,
401
+ :query_params => query_params,
402
+ :form_params => form_params,
403
+ :body => post_body,
404
+ :auth_names => auth_names,
405
+ :return_type => 'ConversationStartResponse')
406
+ if @api_client.config.debugging
407
+ @api_client.config.logger.debug "API called: ConversationApi#start_conversation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
408
+ end
409
+ return data, status_code, headers
410
+ end
411
+ end
412
+ end
@@ -857,6 +857,69 @@ module UltracartClient
857
857
  end
858
858
  return data, status_code, headers
859
859
  end
860
+ # Merge customer into this customer
861
+ # Merge customer into this customer.
862
+ # @param customer Customer to merge into this profile.
863
+ # @param customer_profile_oid The customer_profile_oid to update.
864
+ # @param [Hash] opts the optional parameters
865
+ # @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples
866
+ # @return [nil]
867
+ def merge_customer(customer, customer_profile_oid, opts = {})
868
+ merge_customer_with_http_info(customer, customer_profile_oid, opts)
869
+ nil
870
+ end
871
+
872
+ # Merge customer into this customer
873
+ # Merge customer into this customer.
874
+ # @param customer Customer to merge into this profile.
875
+ # @param customer_profile_oid The customer_profile_oid to update.
876
+ # @param [Hash] opts the optional parameters
877
+ # @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples
878
+ # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
879
+ def merge_customer_with_http_info(customer, customer_profile_oid, opts = {})
880
+ if @api_client.config.debugging
881
+ @api_client.config.logger.debug 'Calling API: CustomerApi.merge_customer ...'
882
+ end
883
+ # verify the required parameter 'customer' is set
884
+ if @api_client.config.client_side_validation && customer.nil?
885
+ fail ArgumentError, "Missing the required parameter 'customer' when calling CustomerApi.merge_customer"
886
+ end
887
+ # verify the required parameter 'customer_profile_oid' is set
888
+ if @api_client.config.client_side_validation && customer_profile_oid.nil?
889
+ fail ArgumentError, "Missing the required parameter 'customer_profile_oid' when calling CustomerApi.merge_customer"
890
+ end
891
+ # resource path
892
+ local_var_path = '/customer/customers/{customer_profile_oid}/merge'.sub('{' + 'customer_profile_oid' + '}', customer_profile_oid.to_s)
893
+
894
+ # query parameters
895
+ query_params = {}
896
+ query_params[:'_expand'] = opts[:'_expand'] if !opts[:'_expand'].nil?
897
+
898
+ # header parameters
899
+ header_params = {}
900
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
901
+ # HTTP header 'Accept' (if needed)
902
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
903
+ # HTTP header 'Content-Type'
904
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json; charset=UTF-8'])
905
+
906
+ # form parameters
907
+ form_params = {}
908
+
909
+ # http body (model)
910
+ post_body = @api_client.object_to_http_body(customer)
911
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
912
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
913
+ :header_params => header_params,
914
+ :query_params => query_params,
915
+ :form_params => form_params,
916
+ :body => post_body,
917
+ :auth_names => auth_names)
918
+ if @api_client.config.debugging
919
+ @api_client.config.logger.debug "API called: CustomerApi#merge_customer\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
920
+ end
921
+ return data, status_code, headers
922
+ end
860
923
  # Searches for all matching values (using POST)
861
924
  # @param lookup_request LookupRequest
862
925
  # @param [Hash] opts the optional parameters
@@ -16,8 +16,12 @@ module UltracartClient
16
16
  class Activity
17
17
  attr_accessor :action
18
18
 
19
+ attr_accessor :channel
20
+
19
21
  attr_accessor :metric
20
22
 
23
+ attr_accessor :storefront_oid
24
+
21
25
  attr_accessor :subject
22
26
 
23
27
  attr_accessor :ts
@@ -30,7 +34,9 @@ module UltracartClient
30
34
  def self.attribute_map
31
35
  {
32
36
  :'action' => :'action',
37
+ :'channel' => :'channel',
33
38
  :'metric' => :'metric',
39
+ :'storefront_oid' => :'storefront_oid',
34
40
  :'subject' => :'subject',
35
41
  :'ts' => :'ts',
36
42
  :'type' => :'type',
@@ -42,7 +48,9 @@ module UltracartClient
42
48
  def self.swagger_types
43
49
  {
44
50
  :'action' => :'String',
51
+ :'channel' => :'String',
45
52
  :'metric' => :'String',
53
+ :'storefront_oid' => :'Integer',
46
54
  :'subject' => :'String',
47
55
  :'ts' => :'Integer',
48
56
  :'type' => :'String',
@@ -62,10 +70,18 @@ module UltracartClient
62
70
  self.action = attributes[:'action']
63
71
  end
64
72
 
73
+ if attributes.has_key?(:'channel')
74
+ self.channel = attributes[:'channel']
75
+ end
76
+
65
77
  if attributes.has_key?(:'metric')
66
78
  self.metric = attributes[:'metric']
67
79
  end
68
80
 
81
+ if attributes.has_key?(:'storefront_oid')
82
+ self.storefront_oid = attributes[:'storefront_oid']
83
+ end
84
+
69
85
  if attributes.has_key?(:'subject')
70
86
  self.subject = attributes[:'subject']
71
87
  end
@@ -102,7 +118,9 @@ module UltracartClient
102
118
  return true if self.equal?(o)
103
119
  self.class == o.class &&
104
120
  action == o.action &&
121
+ channel == o.channel &&
105
122
  metric == o.metric &&
123
+ storefront_oid == o.storefront_oid &&
106
124
  subject == o.subject &&
107
125
  ts == o.ts &&
108
126
  type == o.type &&
@@ -118,7 +136,7 @@ module UltracartClient
118
136
  # Calculates hash code according to all attributes.
119
137
  # @return [Fixnum] Hash code
120
138
  def hash
121
- [action, metric, subject, ts, type, uuid].hash
139
+ [action, channel, metric, storefront_oid, subject, ts, type, uuid].hash
122
140
  end
123
141
 
124
142
  # Builds the object from hash