MailchimpMarketing 3.0.5 → 3.0.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. checksums.yaml +4 -4
  2. data/MailchimpMarketing.gemspec +1 -1
  3. data/README.md +22 -26
  4. data/lib/MailchimpMarketing.rb +1 -1
  5. data/lib/MailchimpMarketing/api/activity_feed_api.rb +11 -67
  6. data/lib/MailchimpMarketing/api/authorized_apps_api.rb +17 -110
  7. data/lib/MailchimpMarketing/api/automations_api.rb +111 -666
  8. data/lib/MailchimpMarketing/api/batch_webhooks_api.rb +28 -177
  9. data/lib/MailchimpMarketing/api/batches_api.rb +22 -142
  10. data/lib/MailchimpMarketing/api/campaign_folders_api.rb +28 -177
  11. data/lib/MailchimpMarketing/api/campaigns_api.rb +125 -784
  12. data/lib/MailchimpMarketing/api/connected_sites_api.rb +27 -174
  13. data/lib/MailchimpMarketing/api/conversations_api.rb +31 -200
  14. data/lib/MailchimpMarketing/api/dashboard_api.rb +26 -215
  15. data/lib/MailchimpMarketing/api/ecommerce_api.rb +388 -2253
  16. data/lib/MailchimpMarketing/api/external_auths_api.rb +17 -110
  17. data/lib/MailchimpMarketing/api/facebook_ads_api.rb +14 -81
  18. data/lib/MailchimpMarketing/api/file_manager_api.rb +60 -402
  19. data/lib/MailchimpMarketing/api/landing_pages_api.rb +45 -280
  20. data/lib/MailchimpMarketing/api/lists_api.rb +420 -2575
  21. data/lib/MailchimpMarketing/api/ping_api.rb +6 -32
  22. data/lib/MailchimpMarketing/api/postcards_api.rb +8 -40
  23. data/lib/MailchimpMarketing/api/reporting_api.rb +35 -231
  24. data/lib/MailchimpMarketing/api/reports_api.rb +131 -881
  25. data/lib/MailchimpMarketing/api/root_api.rb +6 -36
  26. data/lib/MailchimpMarketing/api/search_campaigns_api.rb +7 -38
  27. data/lib/MailchimpMarketing/api/search_members_api.rb +7 -40
  28. data/lib/MailchimpMarketing/api/template_folders_api.rb +28 -177
  29. data/lib/MailchimpMarketing/api/templates_api.rb +34 -228
  30. data/lib/MailchimpMarketing/api/verified_domains_api.rb +27 -165
  31. data/lib/MailchimpMarketing/api_client.rb +11 -55
  32. data/lib/MailchimpMarketing/api_error.rb +1 -1
  33. data/lib/MailchimpMarketing/configuration.rb +1 -1
  34. data/lib/MailchimpMarketing/version.rb +2 -2
  35. metadata +2 -2
@@ -3,7 +3,7 @@
3
3
 
4
4
  #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
5
 
6
- OpenAPI spec version: 3.0.5
6
+ OpenAPI spec version: 3.0.6
7
7
  Contact: apihelp@mailchimp.com
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
9
  Swagger Codegen version: 2.4.12
@@ -11,6 +11,7 @@ Swagger Codegen version: 2.4.12
11
11
  =end
12
12
 
13
13
  require 'uri'
14
+ require 'json'
14
15
 
15
16
  module MailchimpMarketing
16
17
  class DashboardApi
@@ -19,298 +20,108 @@ module MailchimpMarketing
19
20
  def initialize(api_client)
20
21
  @api_client = api_client
21
22
  end
22
- # List dashboard ads
23
- # Get all the onboarding ads info for the mobile dashboard
24
- # @param [Hash] opts the optional parameters
25
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
26
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
27
- # @option opts [String] :platform Restrict results to ads compatible with the given platform. Default is ios
28
- # @option opts [Integer] :num Restrict results to this number of ads (if we have that many. Default is 3.
29
- # @return [OnboardingAds]
30
- def ads(opts = {})
31
- data, _status_code, _headers = ads_with_http_info(opts)
32
- data
33
- end
34
23
 
35
24
  # List dashboard ads
36
- # Get all the onboarding ads info for the mobile dashboard
37
- # @param [Hash] opts the optional parameters
38
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
39
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
40
- # @option opts [String] :platform Restrict results to ads compatible with the given platform. Default is ios
41
- # @option opts [Integer] :num Restrict results to this number of ads (if we have that many. Default is 3.
42
- # @return [Array<(OnboardingAds, Fixnum, Hash)>] OnboardingAds data, response status code and response headers
43
- def ads_with_http_info(opts = {})
44
- # resource path
45
- local_var_path = '/dashboard/ads'
25
+ def ads(opts = {})
46
26
 
47
- # query parameters
48
27
  query_params = {}
49
28
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
50
29
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
51
30
  query_params[:'platform'] = opts[:'platform'] if !opts[:'platform'].nil?
52
31
  query_params[:'num'] = opts[:'num'] if !opts[:'num'].nil?
53
-
54
- # header parameters
55
- header_params = {}
56
- # HTTP header 'Accept' (if needed)
57
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
58
- # HTTP header 'Content-Type'
59
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
60
-
61
- # form parameters
62
32
  form_params = {}
63
-
64
- # http body (model)
65
33
  post_body = nil
66
- auth_names = ['basicAuth']
34
+
35
+ local_var_path = '/dashboard/ads'
67
36
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
68
- :header_params => header_params,
69
37
  :query_params => query_params,
70
38
  :form_params => form_params,
71
- :body => post_body,
72
- :auth_names => auth_names,
73
- :return_type => 'OnboardingAds')
39
+ :body => post_body)
74
40
  return data, status_code, headers
75
41
  end
76
- # List dashboard audiences
77
- # Get all the audiences info for the mobile dashboard
78
- # @param [Hash] opts the optional parameters
79
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
80
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
81
- # @return [Audiences]
82
- def audiences(opts = {})
83
- data, _status_code, _headers = audiences_with_http_info(opts)
84
- data
85
- end
86
42
 
87
43
  # List dashboard audiences
88
- # Get all the audiences info for the mobile dashboard
89
- # @param [Hash] opts the optional parameters
90
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
91
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
92
- # @return [Array<(Audiences, Fixnum, Hash)>] Audiences data, response status code and response headers
93
- def audiences_with_http_info(opts = {})
94
- # resource path
95
- local_var_path = '/dashboard/audiences'
44
+ def audiences(opts = {})
96
45
 
97
- # query parameters
98
46
  query_params = {}
99
47
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
100
48
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
101
-
102
- # header parameters
103
- header_params = {}
104
- # HTTP header 'Accept' (if needed)
105
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
106
- # HTTP header 'Content-Type'
107
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
108
-
109
- # form parameters
110
49
  form_params = {}
111
-
112
- # http body (model)
113
50
  post_body = nil
114
- auth_names = ['basicAuth']
51
+
52
+ local_var_path = '/dashboard/audiences'
115
53
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
116
- :header_params => header_params,
117
54
  :query_params => query_params,
118
55
  :form_params => form_params,
119
- :body => post_body,
120
- :auth_names => auth_names,
121
- :return_type => 'Audiences')
56
+ :body => post_body)
122
57
  return data, status_code, headers
123
58
  end
124
- # List dashboard charts
125
- # Get info about which dashboard charts to show for this user
126
- # @param [Hash] opts the optional parameters
127
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
128
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
129
- # @return [Charts]
130
- def charts(opts = {})
131
- data, _status_code, _headers = charts_with_http_info(opts)
132
- data
133
- end
134
59
 
135
60
  # List dashboard charts
136
- # Get info about which dashboard charts to show for this user
137
- # @param [Hash] opts the optional parameters
138
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
139
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
140
- # @return [Array<(Charts, Fixnum, Hash)>] Charts data, response status code and response headers
141
- def charts_with_http_info(opts = {})
142
- # resource path
143
- local_var_path = '/dashboard/charts'
61
+ def charts(opts = {})
144
62
 
145
- # query parameters
146
63
  query_params = {}
147
64
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
148
65
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
149
-
150
- # header parameters
151
- header_params = {}
152
- # HTTP header 'Accept' (if needed)
153
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
154
- # HTTP header 'Content-Type'
155
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
156
-
157
- # form parameters
158
66
  form_params = {}
159
-
160
- # http body (model)
161
67
  post_body = nil
162
- auth_names = ['basicAuth']
68
+
69
+ local_var_path = '/dashboard/charts'
163
70
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
164
- :header_params => header_params,
165
71
  :query_params => query_params,
166
72
  :form_params => form_params,
167
- :body => post_body,
168
- :auth_names => auth_names,
169
- :return_type => 'Charts')
73
+ :body => post_body)
170
74
  return data, status_code, headers
171
75
  end
172
- # List dashboard ecommerce info
173
- # Get all the ecommerce info for the mobile dashboard
174
- # @param [Hash] opts the optional parameters
175
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
176
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
177
- # @return [Ecommerce]
178
- def ecommerce(opts = {})
179
- data, _status_code, _headers = ecommerce_with_http_info(opts)
180
- data
181
- end
182
76
 
183
77
  # List dashboard ecommerce info
184
- # Get all the ecommerce info for the mobile dashboard
185
- # @param [Hash] opts the optional parameters
186
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
187
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
188
- # @return [Array<(Ecommerce, Fixnum, Hash)>] Ecommerce data, response status code and response headers
189
- def ecommerce_with_http_info(opts = {})
190
- # resource path
191
- local_var_path = '/dashboard/ecommerce'
78
+ def ecommerce(opts = {})
192
79
 
193
- # query parameters
194
80
  query_params = {}
195
81
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
196
82
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
197
-
198
- # header parameters
199
- header_params = {}
200
- # HTTP header 'Accept' (if needed)
201
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
202
- # HTTP header 'Content-Type'
203
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
204
-
205
- # form parameters
206
83
  form_params = {}
207
-
208
- # http body (model)
209
84
  post_body = nil
210
- auth_names = ['basicAuth']
85
+
86
+ local_var_path = '/dashboard/ecommerce'
211
87
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
212
- :header_params => header_params,
213
88
  :query_params => query_params,
214
89
  :form_params => form_params,
215
- :body => post_body,
216
- :auth_names => auth_names,
217
- :return_type => 'Ecommerce')
90
+ :body => post_body)
218
91
  return data, status_code, headers
219
92
  end
220
- # List dashboard engagement info
221
- # Get all the engagement info for the mobile dashboard
222
- # @param [Hash] opts the optional parameters
223
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
224
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
225
- # @return [DataAboutEngagement]
226
- def engagement(opts = {})
227
- data, _status_code, _headers = engagement_with_http_info(opts)
228
- data
229
- end
230
93
 
231
94
  # List dashboard engagement info
232
- # Get all the engagement info for the mobile dashboard
233
- # @param [Hash] opts the optional parameters
234
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
235
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
236
- # @return [Array<(DataAboutEngagement, Fixnum, Hash)>] DataAboutEngagement data, response status code and response headers
237
- def engagement_with_http_info(opts = {})
238
- # resource path
239
- local_var_path = '/dashboard/engagement'
95
+ def engagement(opts = {})
240
96
 
241
- # query parameters
242
97
  query_params = {}
243
98
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
244
99
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
245
-
246
- # header parameters
247
- header_params = {}
248
- # HTTP header 'Accept' (if needed)
249
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
250
- # HTTP header 'Content-Type'
251
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
252
-
253
- # form parameters
254
100
  form_params = {}
255
-
256
- # http body (model)
257
101
  post_body = nil
258
- auth_names = ['basicAuth']
102
+
103
+ local_var_path = '/dashboard/engagement'
259
104
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
260
- :header_params => header_params,
261
105
  :query_params => query_params,
262
106
  :form_params => form_params,
263
- :body => post_body,
264
- :auth_names => auth_names,
265
- :return_type => 'DataAboutEngagement')
107
+ :body => post_body)
266
108
  return data, status_code, headers
267
109
  end
268
- # List dashboard homepage metrics
269
- # Get all the metrics for the Homepage
270
- # @param [Hash] opts the optional parameters
271
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
272
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
273
- # @return [DataForHomepage]
274
- def homepage(opts = {})
275
- data, _status_code, _headers = homepage_with_http_info(opts)
276
- data
277
- end
278
110
 
279
111
  # List dashboard homepage metrics
280
- # Get all the metrics for the Homepage
281
- # @param [Hash] opts the optional parameters
282
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
283
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
284
- # @return [Array<(DataForHomepage, Fixnum, Hash)>] DataForHomepage data, response status code and response headers
285
- def homepage_with_http_info(opts = {})
286
- # resource path
287
- local_var_path = '/dashboard/homepage'
112
+ def homepage(opts = {})
288
113
 
289
- # query parameters
290
114
  query_params = {}
291
115
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
292
116
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
293
-
294
- # header parameters
295
- header_params = {}
296
- # HTTP header 'Accept' (if needed)
297
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
298
- # HTTP header 'Content-Type'
299
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
300
-
301
- # form parameters
302
117
  form_params = {}
303
-
304
- # http body (model)
305
118
  post_body = nil
306
- auth_names = ['basicAuth']
119
+
120
+ local_var_path = '/dashboard/homepage'
307
121
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
308
- :header_params => header_params,
309
122
  :query_params => query_params,
310
123
  :form_params => form_params,
311
- :body => post_body,
312
- :auth_names => auth_names,
313
- :return_type => 'DataForHomepage')
124
+ :body => post_body)
314
125
  return data, status_code, headers
315
126
  end
316
127
  end
@@ -3,7 +3,7 @@
3
3
 
4
4
  #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
5
 
6
- OpenAPI spec version: 3.0.5
6
+ OpenAPI spec version: 3.0.6
7
7
  Contact: apihelp@mailchimp.com
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
9
  Swagger Codegen version: 2.4.12
@@ -11,6 +11,7 @@ Swagger Codegen version: 2.4.12
11
11
  =end
12
12
 
13
13
  require 'uri'
14
+ require 'json'
14
15
 
15
16
  module MailchimpMarketing
16
17
  class EcommerceApi
@@ -19,585 +20,217 @@ module MailchimpMarketing
19
20
  def initialize(api_client)
20
21
  @api_client = api_client
21
22
  end
22
- # Delete store
23
- # Delete a store. Deleting a store will also delete any associated subresources, including Customers, Orders, Products, and Carts.
24
- # @param store_id The store id.
25
- # @param [Hash] opts the optional parameters
26
- # @return [nil]
27
- def delete_store(store_id = {}, opts = {})
28
- delete_store_with_http_info(store_id, opts)
29
- nil
30
- end
31
23
 
32
24
  # Delete store
33
- # Delete a store. Deleting a store will also delete any associated subresources, including Customers, Orders, Products, and Carts.
34
- # @param store_id The store id.
35
- # @param [Hash] opts the optional parameters
36
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
37
- def delete_store_with_http_info(store_id, opts = {})
38
- # resource path
39
- local_var_path = '/ecommerce/stores/{store_id}'.sub('{' + 'store_id' + '}', store_id.to_s)
25
+ def delete_store(store_id, opts = {})
26
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
40
27
 
41
- # query parameters
42
28
  query_params = {}
43
-
44
- # header parameters
45
- header_params = {}
46
- # HTTP header 'Accept' (if needed)
47
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
48
- # HTTP header 'Content-Type'
49
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
50
-
51
- # form parameters
52
29
  form_params = {}
53
-
54
- # http body (model)
55
30
  post_body = nil
56
- auth_names = ['basicAuth']
31
+
32
+ local_var_path = '/ecommerce/stores/{store_id}'.sub('{' + 'store_id' + '}', store_id.to_s)
57
33
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
58
- :header_params => header_params,
59
34
  :query_params => query_params,
60
35
  :form_params => form_params,
61
- :body => post_body,
62
- :auth_names => auth_names)
36
+ :body => post_body)
63
37
  return data, status_code, headers
64
38
  end
65
- # Delete cart
66
- # Delete a cart.
67
- # @param store_id The store id.
68
- # @param cart_id The id for the cart.
69
- # @param [Hash] opts the optional parameters
70
- # @return [nil]
71
- def delete_store_cart(store_id = {}, cart_id = {}, opts = {})
72
- delete_store_cart_with_http_info(store_id, cart_id, opts)
73
- nil
74
- end
75
39
 
76
40
  # Delete cart
77
- # Delete a cart.
78
- # @param store_id The store id.
79
- # @param cart_id The id for the cart.
80
- # @param [Hash] opts the optional parameters
81
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
82
- def delete_store_cart_with_http_info(store_id, cart_id, opts = {})
83
- # resource path
84
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
41
+ def delete_store_cart(store_id, cart_id, opts = {})
42
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
43
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
85
44
 
86
- # query parameters
87
45
  query_params = {}
88
-
89
- # header parameters
90
- header_params = {}
91
- # HTTP header 'Accept' (if needed)
92
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
93
- # HTTP header 'Content-Type'
94
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
95
-
96
- # form parameters
97
46
  form_params = {}
98
-
99
- # http body (model)
100
47
  post_body = nil
101
- auth_names = ['basicAuth']
48
+
49
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
102
50
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
103
- :header_params => header_params,
104
51
  :query_params => query_params,
105
52
  :form_params => form_params,
106
- :body => post_body,
107
- :auth_names => auth_names)
53
+ :body => post_body)
108
54
  return data, status_code, headers
109
55
  end
110
- # Delete cart line item
111
- # Delete a specific cart line item.
112
- # @param store_id The store id.
113
- # @param cart_id The id for the cart.
114
- # @param line_id The id for the line item of a cart.
115
- # @param [Hash] opts the optional parameters
116
- # @return [nil]
117
- def delete_cart_line_item(store_id = {}, cart_id = {}, line_id = {}, opts = {})
118
- delete_cart_line_item_with_http_info(store_id, cart_id, line_id, opts)
119
- nil
120
- end
121
56
 
122
57
  # Delete cart line item
123
- # Delete a specific cart line item.
124
- # @param store_id The store id.
125
- # @param cart_id The id for the cart.
126
- # @param line_id The id for the line item of a cart.
127
- # @param [Hash] opts the optional parameters
128
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
129
- def delete_cart_line_item_with_http_info(store_id, cart_id, line_id, opts = {})
130
- # resource path
131
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
58
+ def delete_cart_line_item(store_id, cart_id, line_id, opts = {})
59
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
60
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
61
+ fail ArgumentError, "Missing required param: 'line_id'" if line_id.nil?
132
62
 
133
- # query parameters
134
63
  query_params = {}
135
-
136
- # header parameters
137
- header_params = {}
138
- # HTTP header 'Accept' (if needed)
139
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
140
- # HTTP header 'Content-Type'
141
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
142
-
143
- # form parameters
144
64
  form_params = {}
145
-
146
- # http body (model)
147
65
  post_body = nil
148
- auth_names = ['basicAuth']
66
+
67
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
149
68
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
150
- :header_params => header_params,
151
69
  :query_params => query_params,
152
70
  :form_params => form_params,
153
- :body => post_body,
154
- :auth_names => auth_names)
71
+ :body => post_body)
155
72
  return data, status_code, headers
156
73
  end
157
- # Delete customer
158
- # Delete a customer from a store.
159
- # @param store_id The store id.
160
- # @param customer_id The id for the customer of a store.
161
- # @param [Hash] opts the optional parameters
162
- # @return [nil]
163
- def delete_store_customer(store_id = {}, customer_id = {}, opts = {})
164
- delete_store_customer_with_http_info(store_id, customer_id, opts)
165
- nil
166
- end
167
74
 
168
75
  # Delete customer
169
- # Delete a customer from a store.
170
- # @param store_id The store id.
171
- # @param customer_id The id for the customer of a store.
172
- # @param [Hash] opts the optional parameters
173
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
174
- def delete_store_customer_with_http_info(store_id, customer_id, opts = {})
175
- # resource path
176
- local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
76
+ def delete_store_customer(store_id, customer_id, opts = {})
77
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
78
+ fail ArgumentError, "Missing required param: 'customer_id'" if customer_id.nil?
177
79
 
178
- # query parameters
179
80
  query_params = {}
180
-
181
- # header parameters
182
- header_params = {}
183
- # HTTP header 'Accept' (if needed)
184
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
185
- # HTTP header 'Content-Type'
186
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
187
-
188
- # form parameters
189
81
  form_params = {}
190
-
191
- # http body (model)
192
82
  post_body = nil
193
- auth_names = ['basicAuth']
83
+
84
+ local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
194
85
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
195
- :header_params => header_params,
196
86
  :query_params => query_params,
197
87
  :form_params => form_params,
198
- :body => post_body,
199
- :auth_names => auth_names)
88
+ :body => post_body)
200
89
  return data, status_code, headers
201
90
  end
202
- # Delete order
203
- # Delete an order.
204
- # @param store_id The store id.
205
- # @param order_id The id for the order in a store.
206
- # @param [Hash] opts the optional parameters
207
- # @return [nil]
208
- def delete_order(store_id = {}, order_id = {}, opts = {})
209
- delete_order_with_http_info(store_id, order_id, opts)
210
- nil
211
- end
212
91
 
213
92
  # Delete order
214
- # Delete an order.
215
- # @param store_id The store id.
216
- # @param order_id The id for the order in a store.
217
- # @param [Hash] opts the optional parameters
218
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
219
- def delete_order_with_http_info(store_id, order_id, opts = {})
220
- # resource path
221
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
93
+ def delete_order(store_id, order_id, opts = {})
94
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
95
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
222
96
 
223
- # query parameters
224
97
  query_params = {}
225
-
226
- # header parameters
227
- header_params = {}
228
- # HTTP header 'Accept' (if needed)
229
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
230
- # HTTP header 'Content-Type'
231
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
232
-
233
- # form parameters
234
98
  form_params = {}
235
-
236
- # http body (model)
237
99
  post_body = nil
238
- auth_names = ['basicAuth']
100
+
101
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
239
102
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
240
- :header_params => header_params,
241
103
  :query_params => query_params,
242
104
  :form_params => form_params,
243
- :body => post_body,
244
- :auth_names => auth_names)
105
+ :body => post_body)
245
106
  return data, status_code, headers
246
107
  end
247
- # Delete order line item
248
- # Delete a specific order line item.
249
- # @param store_id The store id.
250
- # @param order_id The id for the order in a store.
251
- # @param line_id The id for the line item of an order.
252
- # @param [Hash] opts the optional parameters
253
- # @return [nil]
254
- def delete_order_line_item(store_id = {}, order_id = {}, line_id = {}, opts = {})
255
- delete_order_line_item_with_http_info(store_id, order_id, line_id, opts)
256
- nil
257
- end
258
108
 
259
109
  # Delete order line item
260
- # Delete a specific order line item.
261
- # @param store_id The store id.
262
- # @param order_id The id for the order in a store.
263
- # @param line_id The id for the line item of an order.
264
- # @param [Hash] opts the optional parameters
265
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
266
- def delete_order_line_item_with_http_info(store_id, order_id, line_id, opts = {})
267
- # resource path
268
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
110
+ def delete_order_line_item(store_id, order_id, line_id, opts = {})
111
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
112
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
113
+ fail ArgumentError, "Missing required param: 'line_id'" if line_id.nil?
269
114
 
270
- # query parameters
271
115
  query_params = {}
272
-
273
- # header parameters
274
- header_params = {}
275
- # HTTP header 'Accept' (if needed)
276
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
277
- # HTTP header 'Content-Type'
278
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
279
-
280
- # form parameters
281
116
  form_params = {}
282
-
283
- # http body (model)
284
117
  post_body = nil
285
- auth_names = ['basicAuth']
118
+
119
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
286
120
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
287
- :header_params => header_params,
288
121
  :query_params => query_params,
289
122
  :form_params => form_params,
290
- :body => post_body,
291
- :auth_names => auth_names)
123
+ :body => post_body)
292
124
  return data, status_code, headers
293
125
  end
294
- # Delete product
295
- # Delete a product.
296
- # @param store_id The store id.
297
- # @param product_id The id for the product of a store.
298
- # @param [Hash] opts the optional parameters
299
- # @return [nil]
300
- def delete_store_product(store_id = {}, product_id = {}, opts = {})
301
- delete_store_product_with_http_info(store_id, product_id, opts)
302
- nil
303
- end
304
126
 
305
127
  # Delete product
306
- # Delete a product.
307
- # @param store_id The store id.
308
- # @param product_id The id for the product of a store.
309
- # @param [Hash] opts the optional parameters
310
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
311
- def delete_store_product_with_http_info(store_id, product_id, opts = {})
312
- # resource path
313
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
128
+ def delete_store_product(store_id, product_id, opts = {})
129
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
130
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
314
131
 
315
- # query parameters
316
132
  query_params = {}
317
-
318
- # header parameters
319
- header_params = {}
320
- # HTTP header 'Accept' (if needed)
321
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
322
- # HTTP header 'Content-Type'
323
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
324
-
325
- # form parameters
326
133
  form_params = {}
327
-
328
- # http body (model)
329
134
  post_body = nil
330
- auth_names = ['basicAuth']
135
+
136
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
331
137
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
332
- :header_params => header_params,
333
138
  :query_params => query_params,
334
139
  :form_params => form_params,
335
- :body => post_body,
336
- :auth_names => auth_names)
140
+ :body => post_body)
337
141
  return data, status_code, headers
338
142
  end
339
- # Delete product image
340
- # Delete a product image.
341
- # @param store_id The store id.
342
- # @param product_id The id for the product of a store.
343
- # @param image_id The id for the product image.
344
- # @param [Hash] opts the optional parameters
345
- # @return [nil]
346
- def delete_product_image(store_id = {}, product_id = {}, image_id = {}, opts = {})
347
- delete_product_image_with_http_info(store_id, product_id, image_id, opts)
348
- nil
349
- end
350
143
 
351
144
  # Delete product image
352
- # Delete a product image.
353
- # @param store_id The store id.
354
- # @param product_id The id for the product of a store.
355
- # @param image_id The id for the product image.
356
- # @param [Hash] opts the optional parameters
357
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
358
- def delete_product_image_with_http_info(store_id, product_id, image_id, opts = {})
359
- # resource path
360
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images/{image_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'image_id' + '}', image_id.to_s)
145
+ def delete_product_image(store_id, product_id, image_id, opts = {})
146
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
147
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
148
+ fail ArgumentError, "Missing required param: 'image_id'" if image_id.nil?
361
149
 
362
- # query parameters
363
150
  query_params = {}
364
-
365
- # header parameters
366
- header_params = {}
367
- # HTTP header 'Accept' (if needed)
368
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
369
- # HTTP header 'Content-Type'
370
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
371
-
372
- # form parameters
373
151
  form_params = {}
374
-
375
- # http body (model)
376
152
  post_body = nil
377
- auth_names = ['basicAuth']
153
+
154
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images/{image_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'image_id' + '}', image_id.to_s)
378
155
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
379
- :header_params => header_params,
380
156
  :query_params => query_params,
381
157
  :form_params => form_params,
382
- :body => post_body,
383
- :auth_names => auth_names)
158
+ :body => post_body)
384
159
  return data, status_code, headers
385
160
  end
386
- # Delete product variant
387
- # Delete a product variant.
388
- # @param store_id The store id.
389
- # @param product_id The id for the product of a store.
390
- # @param variant_id The id for the product variant.
391
- # @param [Hash] opts the optional parameters
392
- # @return [nil]
393
- def delete_product_variant(store_id = {}, product_id = {}, variant_id = {}, opts = {})
394
- delete_product_variant_with_http_info(store_id, product_id, variant_id, opts)
395
- nil
396
- end
397
161
 
398
162
  # Delete product variant
399
- # Delete a product variant.
400
- # @param store_id The store id.
401
- # @param product_id The id for the product of a store.
402
- # @param variant_id The id for the product variant.
403
- # @param [Hash] opts the optional parameters
404
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
405
- def delete_product_variant_with_http_info(store_id, product_id, variant_id, opts = {})
406
- # resource path
407
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
163
+ def delete_product_variant(store_id, product_id, variant_id, opts = {})
164
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
165
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
166
+ fail ArgumentError, "Missing required param: 'variant_id'" if variant_id.nil?
408
167
 
409
- # query parameters
410
168
  query_params = {}
411
-
412
- # header parameters
413
- header_params = {}
414
- # HTTP header 'Accept' (if needed)
415
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
416
- # HTTP header 'Content-Type'
417
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
418
-
419
- # form parameters
420
169
  form_params = {}
421
-
422
- # http body (model)
423
170
  post_body = nil
424
- auth_names = ['basicAuth']
171
+
172
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
425
173
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
426
- :header_params => header_params,
427
174
  :query_params => query_params,
428
175
  :form_params => form_params,
429
- :body => post_body,
430
- :auth_names => auth_names)
176
+ :body => post_body)
431
177
  return data, status_code, headers
432
178
  end
433
- # Delete promo code
434
- # Delete a promo code from a store.
435
- # @param store_id The store id.
436
- # @param promo_rule_id The id for the promo rule of a store.
437
- # @param promo_code_id The id for the promo code of a store.
438
- # @param [Hash] opts the optional parameters
439
- # @return [nil]
440
- def delete_promo_code(store_id = {}, promo_rule_id = {}, promo_code_id = {}, opts = {})
441
- delete_promo_code_with_http_info(store_id, promo_rule_id, promo_code_id, opts)
442
- nil
443
- end
444
179
 
445
180
  # Delete promo code
446
- # Delete a promo code from a store.
447
- # @param store_id The store id.
448
- # @param promo_rule_id The id for the promo rule of a store.
449
- # @param promo_code_id The id for the promo code of a store.
450
- # @param [Hash] opts the optional parameters
451
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
452
- def delete_promo_code_with_http_info(store_id, promo_rule_id, promo_code_id, opts = {})
453
- # resource path
454
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes/{promo_code_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'promo_code_id' + '}', promo_code_id.to_s)
181
+ def delete_promo_code(store_id, promo_rule_id, promo_code_id, opts = {})
182
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
183
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
184
+ fail ArgumentError, "Missing required param: 'promo_code_id'" if promo_code_id.nil?
455
185
 
456
- # query parameters
457
186
  query_params = {}
458
-
459
- # header parameters
460
- header_params = {}
461
- # HTTP header 'Accept' (if needed)
462
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
463
- # HTTP header 'Content-Type'
464
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
465
-
466
- # form parameters
467
187
  form_params = {}
468
-
469
- # http body (model)
470
188
  post_body = nil
471
- auth_names = ['basicAuth']
189
+
190
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes/{promo_code_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'promo_code_id' + '}', promo_code_id.to_s)
472
191
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
473
- :header_params => header_params,
474
192
  :query_params => query_params,
475
193
  :form_params => form_params,
476
- :body => post_body,
477
- :auth_names => auth_names)
194
+ :body => post_body)
478
195
  return data, status_code, headers
479
196
  end
480
- # Delete promo rule
481
- # Delete a promo rule from a store.
482
- # @param store_id The store id.
483
- # @param promo_rule_id The id for the promo rule of a store.
484
- # @param [Hash] opts the optional parameters
485
- # @return [nil]
486
- def delete_promo_rule(store_id = {}, promo_rule_id = {}, opts = {})
487
- delete_promo_rule_with_http_info(store_id, promo_rule_id, opts)
488
- nil
489
- end
490
197
 
491
198
  # Delete promo rule
492
- # Delete a promo rule from a store.
493
- # @param store_id The store id.
494
- # @param promo_rule_id The id for the promo rule of a store.
495
- # @param [Hash] opts the optional parameters
496
- # @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
497
- def delete_promo_rule_with_http_info(store_id, promo_rule_id, opts = {})
498
- # resource path
499
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
199
+ def delete_promo_rule(store_id, promo_rule_id, opts = {})
200
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
201
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
500
202
 
501
- # query parameters
502
203
  query_params = {}
503
-
504
- # header parameters
505
- header_params = {}
506
- # HTTP header 'Accept' (if needed)
507
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
508
- # HTTP header 'Content-Type'
509
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
510
-
511
- # form parameters
512
204
  form_params = {}
513
-
514
- # http body (model)
515
205
  post_body = nil
516
- auth_names = ['basicAuth']
206
+
207
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
517
208
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
518
- :header_params => header_params,
519
209
  :query_params => query_params,
520
210
  :form_params => form_params,
521
- :body => post_body,
522
- :auth_names => auth_names)
211
+ :body => post_body)
523
212
  return data, status_code, headers
524
213
  end
525
- # List e commerce api resources
526
- # Get information about the e-commerce endpoint's resources.
527
- # @param [Hash] opts the optional parameters
528
- # @return [EcommerceRoot]
529
- def info(opts = {})
530
- data, _status_code, _headers = info_with_http_info(opts)
531
- data
532
- end
533
214
 
534
215
  # List e commerce api resources
535
- # Get information about the e-commerce endpoint&#39;s resources.
536
- # @param [Hash] opts the optional parameters
537
- # @return [Array<(EcommerceRoot, Fixnum, Hash)>] EcommerceRoot data, response status code and response headers
538
- def info_with_http_info(opts = {})
539
- # resource path
540
- local_var_path = '/ecommerce'
216
+ def info(opts = {})
541
217
 
542
- # query parameters
543
218
  query_params = {}
544
-
545
- # header parameters
546
- header_params = {}
547
- # HTTP header 'Accept' (if needed)
548
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
549
- # HTTP header 'Content-Type'
550
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
551
-
552
- # form parameters
553
219
  form_params = {}
554
-
555
- # http body (model)
556
220
  post_body = nil
557
- auth_names = ['basicAuth']
221
+
222
+ local_var_path = '/ecommerce'
558
223
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
559
- :header_params => header_params,
560
224
  :query_params => query_params,
561
225
  :form_params => form_params,
562
- :body => post_body,
563
- :auth_names => auth_names,
564
- :return_type => 'EcommerceRoot')
226
+ :body => post_body)
565
227
  return data, status_code, headers
566
228
  end
567
- # List account orders
568
- # Get information about an account's orders.
569
- # @param [Hash] opts the optional parameters
570
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
571
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
572
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
573
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
574
- # @option opts [String] :campaign_id Restrict results to orders with a specific &#x60;campaign_id&#x60; value.
575
- # @option opts [String] :outreach_id Restrict results to orders with a specific &#x60;outreach_id&#x60; value.
576
- # @option opts [String] :customer_id Restrict results to orders made by a specific customer.
577
- # @option opts [BOOLEAN] :has_outreach Restrict results to orders that have an outreach attached. For example, an email campaign or Facebook ad.
578
- # @return [Orders1]
579
- def orders(opts = {})
580
- data, _status_code, _headers = orders_with_http_info(opts)
581
- data
582
- end
583
229
 
584
230
  # List account orders
585
- # Get information about an account&#39;s orders.
586
- # @param [Hash] opts the optional parameters
587
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
588
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
589
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
590
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
591
- # @option opts [String] :campaign_id Restrict results to orders with a specific &#x60;campaign_id&#x60; value.
592
- # @option opts [String] :outreach_id Restrict results to orders with a specific &#x60;outreach_id&#x60; value.
593
- # @option opts [String] :customer_id Restrict results to orders made by a specific customer.
594
- # @option opts [BOOLEAN] :has_outreach Restrict results to orders that have an outreach attached. For example, an email campaign or Facebook ad.
595
- # @return [Array<(Orders1, Fixnum, Hash)>] Orders1 data, response status code and response headers
596
- def orders_with_http_info(opts = {})
597
- # resource path
598
- local_var_path = '/ecommerce/orders'
231
+ def orders(opts = {})
232
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
599
233
 
600
- # query parameters
601
234
  query_params = {}
602
235
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
603
236
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
@@ -607,500 +240,183 @@ module MailchimpMarketing
607
240
  query_params[:'outreach_id'] = opts[:'outreach_id'] if !opts[:'outreach_id'].nil?
608
241
  query_params[:'customer_id'] = opts[:'customer_id'] if !opts[:'customer_id'].nil?
609
242
  query_params[:'has_outreach'] = opts[:'has_outreach'] if !opts[:'has_outreach'].nil?
610
-
611
- # header parameters
612
- header_params = {}
613
- # HTTP header 'Accept' (if needed)
614
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
615
- # HTTP header 'Content-Type'
616
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
617
-
618
- # form parameters
619
243
  form_params = {}
620
-
621
- # http body (model)
622
244
  post_body = nil
623
- auth_names = ['basicAuth']
245
+
246
+ local_var_path = '/ecommerce/orders'
624
247
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
625
- :header_params => header_params,
626
248
  :query_params => query_params,
627
249
  :form_params => form_params,
628
- :body => post_body,
629
- :auth_names => auth_names,
630
- :return_type => 'Orders1')
250
+ :body => post_body)
631
251
  return data, status_code, headers
632
252
  end
633
- # List stores
634
- # Get information about all stores in the account.
635
- # @param [Hash] opts the optional parameters
636
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
637
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
638
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
639
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
640
- # @return [EcommerceStores]
641
- def stores(opts = {})
642
- data, _status_code, _headers = stores_with_http_info(opts)
643
- data
644
- end
645
253
 
646
254
  # List stores
647
- # Get information about all stores in the account.
648
- # @param [Hash] opts the optional parameters
649
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
650
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
651
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
652
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
653
- # @return [Array<(EcommerceStores, Fixnum, Hash)>] EcommerceStores data, response status code and response headers
654
- def stores_with_http_info(opts = {})
655
- # resource path
656
- local_var_path = '/ecommerce/stores'
255
+ def stores(opts = {})
256
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
657
257
 
658
- # query parameters
659
258
  query_params = {}
660
259
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
661
260
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
662
261
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
663
262
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
664
-
665
- # header parameters
666
- header_params = {}
667
- # HTTP header 'Accept' (if needed)
668
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
669
- # HTTP header 'Content-Type'
670
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
671
-
672
- # form parameters
673
263
  form_params = {}
674
-
675
- # http body (model)
676
264
  post_body = nil
677
- auth_names = ['basicAuth']
265
+
266
+ local_var_path = '/ecommerce/stores'
678
267
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
679
- :header_params => header_params,
680
268
  :query_params => query_params,
681
269
  :form_params => form_params,
682
- :body => post_body,
683
- :auth_names => auth_names,
684
- :return_type => 'EcommerceStores')
270
+ :body => post_body)
685
271
  return data, status_code, headers
686
272
  end
687
- # Get store info
688
- # Get information about a specific store.
689
- # @param store_id The store id.
690
- # @param [Hash] opts the optional parameters
691
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
692
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
693
- # @return [EcommerceStore]
694
- def get_store(store_id = {}, opts = {})
695
- data, _status_code, _headers = get_store_with_http_info(store_id, opts)
696
- data
697
- end
698
273
 
699
274
  # Get store info
700
- # Get information about a specific store.
701
- # @param store_id The store id.
702
- # @param [Hash] opts the optional parameters
703
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
704
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
705
- # @return [Array<(EcommerceStore, Fixnum, Hash)>] EcommerceStore data, response status code and response headers
706
- def get_store_with_http_info(store_id, opts = {})
707
- # resource path
708
- local_var_path = '/ecommerce/stores/{store_id}'.sub('{' + 'store_id' + '}', store_id.to_s)
275
+ def get_store(store_id, opts = {})
276
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
709
277
 
710
- # query parameters
711
278
  query_params = {}
712
279
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
713
280
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
714
-
715
- # header parameters
716
- header_params = {}
717
- # HTTP header 'Accept' (if needed)
718
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
719
- # HTTP header 'Content-Type'
720
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
721
-
722
- # form parameters
723
281
  form_params = {}
724
-
725
- # http body (model)
726
282
  post_body = nil
727
- auth_names = ['basicAuth']
283
+
284
+ local_var_path = '/ecommerce/stores/{store_id}'.sub('{' + 'store_id' + '}', store_id.to_s)
728
285
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
729
- :header_params => header_params,
730
286
  :query_params => query_params,
731
287
  :form_params => form_params,
732
- :body => post_body,
733
- :auth_names => auth_names,
734
- :return_type => 'EcommerceStore')
288
+ :body => post_body)
735
289
  return data, status_code, headers
736
290
  end
737
- # List carts
738
- # Get information about a store's carts.
739
- # @param store_id The store id.
740
- # @param [Hash] opts the optional parameters
741
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
742
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
743
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
744
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
745
- # @return [Carts2]
746
- def get_store_carts(store_id = {}, opts = {})
747
- data, _status_code, _headers = get_store_carts_with_http_info(store_id, opts)
748
- data
749
- end
750
291
 
751
292
  # List carts
752
- # Get information about a store&#39;s carts.
753
- # @param store_id The store id.
754
- # @param [Hash] opts the optional parameters
755
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
756
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
757
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
758
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
759
- # @return [Array<(Carts2, Fixnum, Hash)>] Carts2 data, response status code and response headers
760
- def get_store_carts_with_http_info(store_id, opts = {})
761
- # resource path
762
- local_var_path = '/ecommerce/stores/{store_id}/carts'.sub('{' + 'store_id' + '}', store_id.to_s)
293
+ def get_store_carts(store_id, opts = {})
294
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
295
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
763
296
 
764
- # query parameters
765
297
  query_params = {}
766
298
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
767
299
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
768
300
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
769
301
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
770
-
771
- # header parameters
772
- header_params = {}
773
- # HTTP header 'Accept' (if needed)
774
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
775
- # HTTP header 'Content-Type'
776
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
777
-
778
- # form parameters
779
302
  form_params = {}
780
-
781
- # http body (model)
782
303
  post_body = nil
783
- auth_names = ['basicAuth']
304
+
305
+ local_var_path = '/ecommerce/stores/{store_id}/carts'.sub('{' + 'store_id' + '}', store_id.to_s)
784
306
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
785
- :header_params => header_params,
786
307
  :query_params => query_params,
787
308
  :form_params => form_params,
788
- :body => post_body,
789
- :auth_names => auth_names,
790
- :return_type => 'Carts2')
309
+ :body => post_body)
791
310
  return data, status_code, headers
792
311
  end
793
- # Get cart info
794
- # Get information about a specific cart.
795
- # @param store_id The store id.
796
- # @param cart_id The id for the cart.
797
- # @param [Hash] opts the optional parameters
798
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
799
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
800
- # @return [EcommerceCart]
801
- def get_store_cart(store_id = {}, cart_id = {}, opts = {})
802
- data, _status_code, _headers = get_store_cart_with_http_info(store_id, cart_id, opts)
803
- data
804
- end
805
312
 
806
313
  # Get cart info
807
- # Get information about a specific cart.
808
- # @param store_id The store id.
809
- # @param cart_id The id for the cart.
810
- # @param [Hash] opts the optional parameters
811
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
812
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
813
- # @return [Array<(EcommerceCart, Fixnum, Hash)>] EcommerceCart data, response status code and response headers
814
- def get_store_cart_with_http_info(store_id, cart_id, opts = {})
815
- # resource path
816
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
314
+ def get_store_cart(store_id, cart_id, opts = {})
315
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
316
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
817
317
 
818
- # query parameters
819
318
  query_params = {}
820
319
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
821
320
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
822
-
823
- # header parameters
824
- header_params = {}
825
- # HTTP header 'Accept' (if needed)
826
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
827
- # HTTP header 'Content-Type'
828
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
829
-
830
- # form parameters
831
321
  form_params = {}
832
-
833
- # http body (model)
834
322
  post_body = nil
835
- auth_names = ['basicAuth']
323
+
324
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
836
325
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
837
- :header_params => header_params,
838
326
  :query_params => query_params,
839
327
  :form_params => form_params,
840
- :body => post_body,
841
- :auth_names => auth_names,
842
- :return_type => 'EcommerceCart')
328
+ :body => post_body)
843
329
  return data, status_code, headers
844
330
  end
845
- # List cart line items
846
- # Get information about a cart's line items.
847
- # @param store_id The store id.
848
- # @param cart_id The id for the cart.
849
- # @param [Hash] opts the optional parameters
850
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
851
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
852
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
853
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
854
- # @return [CartLines]
855
- def get_all_cart_line_items(store_id = {}, cart_id = {}, opts = {})
856
- data, _status_code, _headers = get_all_cart_line_items_with_http_info(store_id, cart_id, opts)
857
- data
858
- end
859
331
 
860
332
  # List cart line items
861
- # Get information about a cart&#39;s line items.
862
- # @param store_id The store id.
863
- # @param cart_id The id for the cart.
864
- # @param [Hash] opts the optional parameters
865
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
866
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
867
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
868
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
869
- # @return [Array<(CartLines, Fixnum, Hash)>] CartLines data, response status code and response headers
870
- def get_all_cart_line_items_with_http_info(store_id, cart_id, opts = {})
871
- # resource path
872
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
333
+ def get_all_cart_line_items(store_id, cart_id, opts = {})
334
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
335
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
336
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
873
337
 
874
- # query parameters
875
338
  query_params = {}
876
339
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
877
340
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
878
341
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
879
342
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
880
-
881
- # header parameters
882
- header_params = {}
883
- # HTTP header 'Accept' (if needed)
884
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
885
- # HTTP header 'Content-Type'
886
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
887
-
888
- # form parameters
889
343
  form_params = {}
890
-
891
- # http body (model)
892
344
  post_body = nil
893
- auth_names = ['basicAuth']
345
+
346
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
894
347
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
895
- :header_params => header_params,
896
348
  :query_params => query_params,
897
349
  :form_params => form_params,
898
- :body => post_body,
899
- :auth_names => auth_names,
900
- :return_type => 'CartLines')
350
+ :body => post_body)
901
351
  return data, status_code, headers
902
352
  end
903
- # Get cart line item
904
- # Get information about a specific cart line item.
905
- # @param store_id The store id.
906
- # @param cart_id The id for the cart.
907
- # @param line_id The id for the line item of a cart.
908
- # @param [Hash] opts the optional parameters
909
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
910
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
911
- # @return [EcommerceCartLineItem]
912
- def get_cart_line_item(store_id = {}, cart_id = {}, line_id = {}, opts = {})
913
- data, _status_code, _headers = get_cart_line_item_with_http_info(store_id, cart_id, line_id, opts)
914
- data
915
- end
916
353
 
917
354
  # Get cart line item
918
- # Get information about a specific cart line item.
919
- # @param store_id The store id.
920
- # @param cart_id The id for the cart.
921
- # @param line_id The id for the line item of a cart.
922
- # @param [Hash] opts the optional parameters
923
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
924
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
925
- # @return [Array<(EcommerceCartLineItem, Fixnum, Hash)>] EcommerceCartLineItem data, response status code and response headers
926
- def get_cart_line_item_with_http_info(store_id, cart_id, line_id, opts = {})
927
- # resource path
928
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
355
+ def get_cart_line_item(store_id, cart_id, line_id, opts = {})
356
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
357
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
358
+ fail ArgumentError, "Missing required param: 'line_id'" if line_id.nil?
929
359
 
930
- # query parameters
931
360
  query_params = {}
932
361
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
933
362
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
934
-
935
- # header parameters
936
- header_params = {}
937
- # HTTP header 'Accept' (if needed)
938
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
939
- # HTTP header 'Content-Type'
940
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
941
-
942
- # form parameters
943
363
  form_params = {}
944
-
945
- # http body (model)
946
364
  post_body = nil
947
- auth_names = ['basicAuth']
365
+
366
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
948
367
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
949
- :header_params => header_params,
950
368
  :query_params => query_params,
951
369
  :form_params => form_params,
952
- :body => post_body,
953
- :auth_names => auth_names,
954
- :return_type => 'EcommerceCartLineItem')
370
+ :body => post_body)
955
371
  return data, status_code, headers
956
372
  end
957
- # List customers
958
- # Get information about a store's customers.
959
- # @param store_id The store id.
960
- # @param [Hash] opts the optional parameters
961
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
962
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
963
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
964
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
965
- # @option opts [String] :email_address Restrict the response to customers with the email address.
966
- # @return [Customers]
967
- def get_all_store_customers(store_id = {}, opts = {})
968
- data, _status_code, _headers = get_all_store_customers_with_http_info(store_id, opts)
969
- data
970
- end
971
373
 
972
374
  # List customers
973
- # Get information about a store&#39;s customers.
974
- # @param store_id The store id.
975
- # @param [Hash] opts the optional parameters
976
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
977
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
978
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
979
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
980
- # @option opts [String] :email_address Restrict the response to customers with the email address.
981
- # @return [Array<(Customers, Fixnum, Hash)>] Customers data, response status code and response headers
982
- def get_all_store_customers_with_http_info(store_id, opts = {})
983
- # resource path
984
- local_var_path = '/ecommerce/stores/{store_id}/customers'.sub('{' + 'store_id' + '}', store_id.to_s)
375
+ def get_all_store_customers(store_id, opts = {})
376
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
377
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
985
378
 
986
- # query parameters
987
379
  query_params = {}
988
380
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
989
381
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
990
382
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
991
383
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
992
384
  query_params[:'email_address'] = opts[:'email_address'] if !opts[:'email_address'].nil?
993
-
994
- # header parameters
995
- header_params = {}
996
- # HTTP header 'Accept' (if needed)
997
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
998
- # HTTP header 'Content-Type'
999
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1000
-
1001
- # form parameters
1002
385
  form_params = {}
1003
-
1004
- # http body (model)
1005
386
  post_body = nil
1006
- auth_names = ['basicAuth']
387
+
388
+ local_var_path = '/ecommerce/stores/{store_id}/customers'.sub('{' + 'store_id' + '}', store_id.to_s)
1007
389
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1008
- :header_params => header_params,
1009
390
  :query_params => query_params,
1010
391
  :form_params => form_params,
1011
- :body => post_body,
1012
- :auth_names => auth_names,
1013
- :return_type => 'Customers')
392
+ :body => post_body)
1014
393
  return data, status_code, headers
1015
394
  end
1016
- # Get customer info
1017
- # Get information about a specific customer.
1018
- # @param store_id The store id.
1019
- # @param customer_id The id for the customer of a store.
1020
- # @param [Hash] opts the optional parameters
1021
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1022
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1023
- # @return [EcommerceCustomer]
1024
- def get_store_customer(store_id = {}, customer_id = {}, opts = {})
1025
- data, _status_code, _headers = get_store_customer_with_http_info(store_id, customer_id, opts)
1026
- data
1027
- end
1028
395
 
1029
396
  # Get customer info
1030
- # Get information about a specific customer.
1031
- # @param store_id The store id.
1032
- # @param customer_id The id for the customer of a store.
1033
- # @param [Hash] opts the optional parameters
1034
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1035
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1036
- # @return [Array<(EcommerceCustomer, Fixnum, Hash)>] EcommerceCustomer data, response status code and response headers
1037
- def get_store_customer_with_http_info(store_id, customer_id, opts = {})
1038
- # resource path
1039
- local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
397
+ def get_store_customer(store_id, customer_id, opts = {})
398
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
399
+ fail ArgumentError, "Missing required param: 'customer_id'" if customer_id.nil?
1040
400
 
1041
- # query parameters
1042
401
  query_params = {}
1043
402
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1044
403
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1045
-
1046
- # header parameters
1047
- header_params = {}
1048
- # HTTP header 'Accept' (if needed)
1049
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1050
- # HTTP header 'Content-Type'
1051
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1052
-
1053
- # form parameters
1054
404
  form_params = {}
1055
-
1056
- # http body (model)
1057
405
  post_body = nil
1058
- auth_names = ['basicAuth']
406
+
407
+ local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
1059
408
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1060
- :header_params => header_params,
1061
409
  :query_params => query_params,
1062
410
  :form_params => form_params,
1063
- :body => post_body,
1064
- :auth_names => auth_names,
1065
- :return_type => 'EcommerceCustomer')
411
+ :body => post_body)
1066
412
  return data, status_code, headers
1067
413
  end
1068
- # List orders
1069
- # Get information about a store's orders.
1070
- # @param store_id The store id.
1071
- # @param [Hash] opts the optional parameters
1072
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1073
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1074
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
1075
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
1076
- # @option opts [String] :customer_id Restrict results to orders made by a specific customer.
1077
- # @option opts [BOOLEAN] :has_outreach Restrict results to orders that have an outreach attached. For example, an email campaign or Facebook ad.
1078
- # @option opts [String] :campaign_id Restrict results to orders with a specific &#x60;campaign_id&#x60; value.
1079
- # @option opts [String] :outreach_id Restrict results to orders with a specific &#x60;outreach_id&#x60; value.
1080
- # @return [Orders2]
1081
- def get_store_orders(store_id = {}, opts = {})
1082
- data, _status_code, _headers = get_store_orders_with_http_info(store_id, opts)
1083
- data
1084
- end
1085
414
 
1086
415
  # List orders
1087
- # Get information about a store&#39;s orders.
1088
- # @param store_id The store id.
1089
- # @param [Hash] opts the optional parameters
1090
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1091
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1092
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
1093
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
1094
- # @option opts [String] :customer_id Restrict results to orders made by a specific customer.
1095
- # @option opts [BOOLEAN] :has_outreach Restrict results to orders that have an outreach attached. For example, an email campaign or Facebook ad.
1096
- # @option opts [String] :campaign_id Restrict results to orders with a specific &#x60;campaign_id&#x60; value.
1097
- # @option opts [String] :outreach_id Restrict results to orders with a specific &#x60;outreach_id&#x60; value.
1098
- # @return [Array<(Orders2, Fixnum, Hash)>] Orders2 data, response status code and response headers
1099
- def get_store_orders_with_http_info(store_id, opts = {})
1100
- # resource path
1101
- local_var_path = '/ecommerce/stores/{store_id}/orders'.sub('{' + 'store_id' + '}', store_id.to_s)
416
+ def get_store_orders(store_id, opts = {})
417
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
418
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
1102
419
 
1103
- # query parameters
1104
420
  query_params = {}
1105
421
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1106
422
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
@@ -1110,1894 +426,713 @@ module MailchimpMarketing
1110
426
  query_params[:'has_outreach'] = opts[:'has_outreach'] if !opts[:'has_outreach'].nil?
1111
427
  query_params[:'campaign_id'] = opts[:'campaign_id'] if !opts[:'campaign_id'].nil?
1112
428
  query_params[:'outreach_id'] = opts[:'outreach_id'] if !opts[:'outreach_id'].nil?
1113
-
1114
- # header parameters
1115
- header_params = {}
1116
- # HTTP header 'Accept' (if needed)
1117
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1118
- # HTTP header 'Content-Type'
1119
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1120
-
1121
- # form parameters
1122
429
  form_params = {}
1123
-
1124
- # http body (model)
1125
430
  post_body = nil
1126
- auth_names = ['basicAuth']
431
+
432
+ local_var_path = '/ecommerce/stores/{store_id}/orders'.sub('{' + 'store_id' + '}', store_id.to_s)
1127
433
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1128
- :header_params => header_params,
1129
434
  :query_params => query_params,
1130
435
  :form_params => form_params,
1131
- :body => post_body,
1132
- :auth_names => auth_names,
1133
- :return_type => 'Orders2')
436
+ :body => post_body)
1134
437
  return data, status_code, headers
1135
438
  end
1136
- # Get order info
1137
- # Get information about a specific order.
1138
- # @param store_id The store id.
1139
- # @param order_id The id for the order in a store.
1140
- # @param [Hash] opts the optional parameters
1141
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1142
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1143
- # @return [EcommerceOrder]
1144
- def get_order(store_id = {}, order_id = {}, opts = {})
1145
- data, _status_code, _headers = get_order_with_http_info(store_id, order_id, opts)
1146
- data
1147
- end
1148
439
 
1149
440
  # Get order info
1150
- # Get information about a specific order.
1151
- # @param store_id The store id.
1152
- # @param order_id The id for the order in a store.
1153
- # @param [Hash] opts the optional parameters
1154
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1155
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1156
- # @return [Array<(EcommerceOrder, Fixnum, Hash)>] EcommerceOrder data, response status code and response headers
1157
- def get_order_with_http_info(store_id, order_id, opts = {})
1158
- # resource path
1159
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
441
+ def get_order(store_id, order_id, opts = {})
442
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
443
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
1160
444
 
1161
- # query parameters
1162
445
  query_params = {}
1163
446
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1164
447
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1165
-
1166
- # header parameters
1167
- header_params = {}
1168
- # HTTP header 'Accept' (if needed)
1169
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1170
- # HTTP header 'Content-Type'
1171
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1172
-
1173
- # form parameters
1174
448
  form_params = {}
1175
-
1176
- # http body (model)
1177
449
  post_body = nil
1178
- auth_names = ['basicAuth']
450
+
451
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
1179
452
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1180
- :header_params => header_params,
1181
453
  :query_params => query_params,
1182
454
  :form_params => form_params,
1183
- :body => post_body,
1184
- :auth_names => auth_names,
1185
- :return_type => 'EcommerceOrder')
455
+ :body => post_body)
1186
456
  return data, status_code, headers
1187
457
  end
1188
- # List order line items
1189
- # Get information about an order's line items.
1190
- # @param store_id The store id.
1191
- # @param order_id The id for the order in a store.
1192
- # @param [Hash] opts the optional parameters
1193
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1194
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1195
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
1196
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
1197
- # @return [OrderLines]
1198
- def get_all_order_line_items(store_id = {}, order_id = {}, opts = {})
1199
- data, _status_code, _headers = get_all_order_line_items_with_http_info(store_id, order_id, opts)
1200
- data
1201
- end
1202
458
 
1203
459
  # List order line items
1204
- # Get information about an order&#39;s line items.
1205
- # @param store_id The store id.
1206
- # @param order_id The id for the order in a store.
1207
- # @param [Hash] opts the optional parameters
1208
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1209
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1210
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
1211
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
1212
- # @return [Array<(OrderLines, Fixnum, Hash)>] OrderLines data, response status code and response headers
1213
- def get_all_order_line_items_with_http_info(store_id, order_id, opts = {})
1214
- # resource path
1215
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
460
+ def get_all_order_line_items(store_id, order_id, opts = {})
461
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
462
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
463
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
1216
464
 
1217
- # query parameters
1218
465
  query_params = {}
1219
466
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1220
467
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1221
468
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
1222
469
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
1223
-
1224
- # header parameters
1225
- header_params = {}
1226
- # HTTP header 'Accept' (if needed)
1227
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1228
- # HTTP header 'Content-Type'
1229
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1230
-
1231
- # form parameters
1232
470
  form_params = {}
1233
-
1234
- # http body (model)
1235
471
  post_body = nil
1236
- auth_names = ['basicAuth']
472
+
473
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
1237
474
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1238
- :header_params => header_params,
1239
475
  :query_params => query_params,
1240
476
  :form_params => form_params,
1241
- :body => post_body,
1242
- :auth_names => auth_names,
1243
- :return_type => 'OrderLines')
477
+ :body => post_body)
1244
478
  return data, status_code, headers
1245
479
  end
1246
- # Get order line item
1247
- # Get information about a specific order line item.
1248
- # @param store_id The store id.
1249
- # @param order_id The id for the order in a store.
1250
- # @param line_id The id for the line item of an order.
1251
- # @param [Hash] opts the optional parameters
1252
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1253
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1254
- # @return [EcommerceOrderLineItem]
1255
- def get_order_line_item(store_id = {}, order_id = {}, line_id = {}, opts = {})
1256
- data, _status_code, _headers = get_order_line_item_with_http_info(store_id, order_id, line_id, opts)
1257
- data
1258
- end
1259
480
 
1260
481
  # Get order line item
1261
- # Get information about a specific order line item.
1262
- # @param store_id The store id.
1263
- # @param order_id The id for the order in a store.
1264
- # @param line_id The id for the line item of an order.
1265
- # @param [Hash] opts the optional parameters
1266
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1267
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1268
- # @return [Array<(EcommerceOrderLineItem, Fixnum, Hash)>] EcommerceOrderLineItem data, response status code and response headers
1269
- def get_order_line_item_with_http_info(store_id, order_id, line_id, opts = {})
1270
- # resource path
1271
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
482
+ def get_order_line_item(store_id, order_id, line_id, opts = {})
483
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
484
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
485
+ fail ArgumentError, "Missing required param: 'line_id'" if line_id.nil?
1272
486
 
1273
- # query parameters
1274
487
  query_params = {}
1275
488
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1276
489
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1277
-
1278
- # header parameters
1279
- header_params = {}
1280
- # HTTP header 'Accept' (if needed)
1281
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1282
- # HTTP header 'Content-Type'
1283
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1284
-
1285
- # form parameters
1286
490
  form_params = {}
1287
-
1288
- # http body (model)
1289
491
  post_body = nil
1290
- auth_names = ['basicAuth']
492
+
493
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
1291
494
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1292
- :header_params => header_params,
1293
495
  :query_params => query_params,
1294
496
  :form_params => form_params,
1295
- :body => post_body,
1296
- :auth_names => auth_names,
1297
- :return_type => 'EcommerceOrderLineItem')
497
+ :body => post_body)
1298
498
  return data, status_code, headers
1299
499
  end
1300
- # List product
1301
- # Get information about a store's products.
1302
- # @param store_id The store id.
1303
- # @param [Hash] opts the optional parameters
1304
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1305
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1306
- # @option opts [String] :sort_field Returns products sorted by the specified field.
1307
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
1308
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
1309
- # @return [Products]
1310
- def get_all_store_products(store_id = {}, opts = {})
1311
- data, _status_code, _headers = get_all_store_products_with_http_info(store_id, opts)
1312
- data
1313
- end
1314
500
 
1315
501
  # List product
1316
- # Get information about a store&#39;s products.
1317
- # @param store_id The store id.
1318
- # @param [Hash] opts the optional parameters
1319
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1320
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1321
- # @option opts [String] :sort_field Returns products sorted by the specified field.
1322
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
1323
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
1324
- # @return [Array<(Products, Fixnum, Hash)>] Products data, response status code and response headers
1325
- def get_all_store_products_with_http_info(store_id, opts = {})
1326
- # resource path
1327
- local_var_path = '/ecommerce/stores/{store_id}/products'.sub('{' + 'store_id' + '}', store_id.to_s)
502
+ def get_all_store_products(store_id, opts = {})
503
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
504
+ fail ArgumentError, 'invalid value for "sort_field", must be one of title, created_at, price' if opts[:'sort_field'] && !['title', 'created_at', 'price'].include?(opts[:'sort_field'])
505
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
1328
506
 
1329
- # query parameters
1330
507
  query_params = {}
1331
508
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1332
509
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1333
510
  query_params[:'sort_field'] = opts[:'sort_field'] if !opts[:'sort_field'].nil?
1334
511
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
1335
512
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
1336
-
1337
- # header parameters
1338
- header_params = {}
1339
- # HTTP header 'Accept' (if needed)
1340
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1341
- # HTTP header 'Content-Type'
1342
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1343
-
1344
- # form parameters
1345
513
  form_params = {}
1346
-
1347
- # http body (model)
1348
514
  post_body = nil
1349
- auth_names = ['basicAuth']
515
+
516
+ local_var_path = '/ecommerce/stores/{store_id}/products'.sub('{' + 'store_id' + '}', store_id.to_s)
1350
517
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1351
- :header_params => header_params,
1352
518
  :query_params => query_params,
1353
519
  :form_params => form_params,
1354
- :body => post_body,
1355
- :auth_names => auth_names,
1356
- :return_type => 'Products')
520
+ :body => post_body)
1357
521
  return data, status_code, headers
1358
522
  end
1359
- # Get product info
1360
- # Get information about a specific product.
1361
- # @param store_id The store id.
1362
- # @param product_id The id for the product of a store.
1363
- # @param [Hash] opts the optional parameters
1364
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1365
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1366
- # @return [EcommerceProduct]
1367
- def get_store_product(store_id = {}, product_id = {}, opts = {})
1368
- data, _status_code, _headers = get_store_product_with_http_info(store_id, product_id, opts)
1369
- data
1370
- end
1371
523
 
1372
524
  # Get product info
1373
- # Get information about a specific product.
1374
- # @param store_id The store id.
1375
- # @param product_id The id for the product of a store.
1376
- # @param [Hash] opts the optional parameters
1377
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1378
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1379
- # @return [Array<(EcommerceProduct, Fixnum, Hash)>] EcommerceProduct data, response status code and response headers
1380
- def get_store_product_with_http_info(store_id, product_id, opts = {})
1381
- # resource path
1382
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
525
+ def get_store_product(store_id, product_id, opts = {})
526
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
527
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
1383
528
 
1384
- # query parameters
1385
529
  query_params = {}
1386
530
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1387
531
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1388
-
1389
- # header parameters
1390
- header_params = {}
1391
- # HTTP header 'Accept' (if needed)
1392
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1393
- # HTTP header 'Content-Type'
1394
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1395
-
1396
- # form parameters
1397
532
  form_params = {}
1398
-
1399
- # http body (model)
1400
533
  post_body = nil
1401
- auth_names = ['basicAuth']
534
+
535
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
1402
536
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1403
- :header_params => header_params,
1404
537
  :query_params => query_params,
1405
538
  :form_params => form_params,
1406
- :body => post_body,
1407
- :auth_names => auth_names,
1408
- :return_type => 'EcommerceProduct')
539
+ :body => post_body)
1409
540
  return data, status_code, headers
1410
541
  end
1411
- # List product images
1412
- # Get information about a product's images.
1413
- # @param store_id The store id.
1414
- # @param product_id The id for the product of a store.
1415
- # @param [Hash] opts the optional parameters
1416
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1417
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1418
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
1419
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
1420
- # @return [EcommerceProductImages]
1421
- def get_product_images(store_id = {}, product_id = {}, opts = {})
1422
- data, _status_code, _headers = get_product_images_with_http_info(store_id, product_id, opts)
1423
- data
1424
- end
1425
542
 
1426
543
  # List product images
1427
- # Get information about a product&#39;s images.
1428
- # @param store_id The store id.
1429
- # @param product_id The id for the product of a store.
1430
- # @param [Hash] opts the optional parameters
1431
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1432
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1433
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
1434
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
1435
- # @return [Array<(EcommerceProductImages, Fixnum, Hash)>] EcommerceProductImages data, response status code and response headers
1436
- def get_product_images_with_http_info(store_id, product_id, opts = {})
1437
- # resource path
1438
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
544
+ def get_product_images(store_id, product_id, opts = {})
545
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
546
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
547
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
1439
548
 
1440
- # query parameters
1441
549
  query_params = {}
1442
550
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1443
551
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1444
552
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
1445
553
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
1446
-
1447
- # header parameters
1448
- header_params = {}
1449
- # HTTP header 'Accept' (if needed)
1450
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1451
- # HTTP header 'Content-Type'
1452
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1453
-
1454
- # form parameters
1455
554
  form_params = {}
1456
-
1457
- # http body (model)
1458
555
  post_body = nil
1459
- auth_names = ['basicAuth']
556
+
557
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
1460
558
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1461
- :header_params => header_params,
1462
559
  :query_params => query_params,
1463
560
  :form_params => form_params,
1464
- :body => post_body,
1465
- :auth_names => auth_names,
1466
- :return_type => 'EcommerceProductImages')
561
+ :body => post_body)
1467
562
  return data, status_code, headers
1468
563
  end
1469
- # Get product image info
1470
- # Get information about a specific product image.
1471
- # @param store_id The store id.
1472
- # @param product_id The id for the product of a store.
1473
- # @param image_id The id for the product image.
1474
- # @param [Hash] opts the optional parameters
1475
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1476
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1477
- # @return [EcommerceProductImage]
1478
- def get_product_image(store_id = {}, product_id = {}, image_id = {}, opts = {})
1479
- data, _status_code, _headers = get_product_image_with_http_info(store_id, product_id, image_id, opts)
1480
- data
1481
- end
1482
564
 
1483
565
  # Get product image info
1484
- # Get information about a specific product image.
1485
- # @param store_id The store id.
1486
- # @param product_id The id for the product of a store.
1487
- # @param image_id The id for the product image.
1488
- # @param [Hash] opts the optional parameters
1489
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1490
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1491
- # @return [Array<(EcommerceProductImage, Fixnum, Hash)>] EcommerceProductImage data, response status code and response headers
1492
- def get_product_image_with_http_info(store_id, product_id, image_id, opts = {})
1493
- # resource path
1494
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images/{image_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'image_id' + '}', image_id.to_s)
566
+ def get_product_image(store_id, product_id, image_id, opts = {})
567
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
568
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
569
+ fail ArgumentError, "Missing required param: 'image_id'" if image_id.nil?
1495
570
 
1496
- # query parameters
1497
571
  query_params = {}
1498
572
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1499
573
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1500
-
1501
- # header parameters
1502
- header_params = {}
1503
- # HTTP header 'Accept' (if needed)
1504
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1505
- # HTTP header 'Content-Type'
1506
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1507
-
1508
- # form parameters
1509
574
  form_params = {}
1510
-
1511
- # http body (model)
1512
575
  post_body = nil
1513
- auth_names = ['basicAuth']
576
+
577
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images/{image_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'image_id' + '}', image_id.to_s)
1514
578
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1515
- :header_params => header_params,
1516
579
  :query_params => query_params,
1517
580
  :form_params => form_params,
1518
- :body => post_body,
1519
- :auth_names => auth_names,
1520
- :return_type => 'EcommerceProductImage')
581
+ :body => post_body)
1521
582
  return data, status_code, headers
1522
583
  end
1523
- # List product variants
1524
- # Get information about a product's variants.
1525
- # @param store_id The store id.
1526
- # @param product_id The id for the product of a store.
1527
- # @param [Hash] opts the optional parameters
1528
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1529
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1530
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
1531
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
1532
- # @return [EcommerceProductVariants]
1533
- def get_product_variants(store_id = {}, product_id = {}, opts = {})
1534
- data, _status_code, _headers = get_product_variants_with_http_info(store_id, product_id, opts)
1535
- data
1536
- end
1537
584
 
1538
585
  # List product variants
1539
- # Get information about a product&#39;s variants.
1540
- # @param store_id The store id.
1541
- # @param product_id The id for the product of a store.
1542
- # @param [Hash] opts the optional parameters
1543
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1544
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1545
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
1546
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
1547
- # @return [Array<(EcommerceProductVariants, Fixnum, Hash)>] EcommerceProductVariants data, response status code and response headers
1548
- def get_product_variants_with_http_info(store_id, product_id, opts = {})
1549
- # resource path
1550
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
586
+ def get_product_variants(store_id, product_id, opts = {})
587
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
588
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
589
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
1551
590
 
1552
- # query parameters
1553
591
  query_params = {}
1554
592
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1555
593
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1556
594
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
1557
595
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
1558
-
1559
- # header parameters
1560
- header_params = {}
1561
- # HTTP header 'Accept' (if needed)
1562
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1563
- # HTTP header 'Content-Type'
1564
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1565
-
1566
- # form parameters
1567
596
  form_params = {}
1568
-
1569
- # http body (model)
1570
597
  post_body = nil
1571
- auth_names = ['basicAuth']
598
+
599
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
1572
600
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1573
- :header_params => header_params,
1574
601
  :query_params => query_params,
1575
602
  :form_params => form_params,
1576
- :body => post_body,
1577
- :auth_names => auth_names,
1578
- :return_type => 'EcommerceProductVariants')
603
+ :body => post_body)
1579
604
  return data, status_code, headers
1580
605
  end
1581
- # Get product variant info
1582
- # Get information about a specific product variant.
1583
- # @param store_id The store id.
1584
- # @param product_id The id for the product of a store.
1585
- # @param variant_id The id for the product variant.
1586
- # @param [Hash] opts the optional parameters
1587
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1588
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1589
- # @return [EcommerceProductVariant]
1590
- def get_product_variant(store_id = {}, product_id = {}, variant_id = {}, opts = {})
1591
- data, _status_code, _headers = get_product_variant_with_http_info(store_id, product_id, variant_id, opts)
1592
- data
1593
- end
1594
606
 
1595
607
  # Get product variant info
1596
- # Get information about a specific product variant.
1597
- # @param store_id The store id.
1598
- # @param product_id The id for the product of a store.
1599
- # @param variant_id The id for the product variant.
1600
- # @param [Hash] opts the optional parameters
1601
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1602
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1603
- # @return [Array<(EcommerceProductVariant, Fixnum, Hash)>] EcommerceProductVariant data, response status code and response headers
1604
- def get_product_variant_with_http_info(store_id, product_id, variant_id, opts = {})
1605
- # resource path
1606
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
608
+ def get_product_variant(store_id, product_id, variant_id, opts = {})
609
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
610
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
611
+ fail ArgumentError, "Missing required param: 'variant_id'" if variant_id.nil?
1607
612
 
1608
- # query parameters
1609
613
  query_params = {}
1610
614
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1611
615
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1612
-
1613
- # header parameters
1614
- header_params = {}
1615
- # HTTP header 'Accept' (if needed)
1616
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1617
- # HTTP header 'Content-Type'
1618
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1619
-
1620
- # form parameters
1621
616
  form_params = {}
1622
-
1623
- # http body (model)
1624
617
  post_body = nil
1625
- auth_names = ['basicAuth']
618
+
619
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
1626
620
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1627
- :header_params => header_params,
1628
621
  :query_params => query_params,
1629
622
  :form_params => form_params,
1630
- :body => post_body,
1631
- :auth_names => auth_names,
1632
- :return_type => 'EcommerceProductVariant')
623
+ :body => post_body)
1633
624
  return data, status_code, headers
1634
625
  end
1635
- # List promo codes
1636
- # Get information about a store's promo codes.
1637
- # @param promo_rule_id The id for the promo rule of a store.
1638
- # @param store_id The store id.
1639
- # @param [Hash] opts the optional parameters
1640
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1641
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1642
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
1643
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
1644
- # @return [PromoCodes]
1645
- def get_promo_codes(promo_rule_id = {}, store_id = {}, opts = {})
1646
- data, _status_code, _headers = get_promo_codes_with_http_info(promo_rule_id, store_id, opts)
1647
- data
1648
- end
1649
626
 
1650
627
  # List promo codes
1651
- # Get information about a store&#39;s promo codes.
1652
- # @param promo_rule_id The id for the promo rule of a store.
1653
- # @param store_id The store id.
1654
- # @param [Hash] opts the optional parameters
1655
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1656
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1657
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
1658
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
1659
- # @return [Array<(PromoCodes, Fixnum, Hash)>] PromoCodes data, response status code and response headers
1660
- def get_promo_codes_with_http_info(promo_rule_id, store_id, opts = {})
1661
- # resource path
1662
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes'.sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'store_id' + '}', store_id.to_s)
628
+ def get_promo_codes(promo_rule_id, store_id, opts = {})
629
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
630
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
631
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
1663
632
 
1664
- # query parameters
1665
633
  query_params = {}
1666
634
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1667
635
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1668
636
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
1669
637
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
1670
-
1671
- # header parameters
1672
- header_params = {}
1673
- # HTTP header 'Accept' (if needed)
1674
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1675
- # HTTP header 'Content-Type'
1676
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1677
-
1678
- # form parameters
1679
638
  form_params = {}
1680
-
1681
- # http body (model)
1682
639
  post_body = nil
1683
- auth_names = ['basicAuth']
640
+
641
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes'.sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'store_id' + '}', store_id.to_s)
1684
642
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1685
- :header_params => header_params,
1686
643
  :query_params => query_params,
1687
644
  :form_params => form_params,
1688
- :body => post_body,
1689
- :auth_names => auth_names,
1690
- :return_type => 'PromoCodes')
645
+ :body => post_body)
1691
646
  return data, status_code, headers
1692
647
  end
1693
- # Get promo code
1694
- # Get information about a specific promo code.
1695
- # @param store_id The store id.
1696
- # @param promo_rule_id The id for the promo rule of a store.
1697
- # @param promo_code_id The id for the promo code of a store.
1698
- # @param [Hash] opts the optional parameters
1699
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1700
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1701
- # @return [EcommercePromoCode]
1702
- def get_promo_code(store_id = {}, promo_rule_id = {}, promo_code_id = {}, opts = {})
1703
- data, _status_code, _headers = get_promo_code_with_http_info(store_id, promo_rule_id, promo_code_id, opts)
1704
- data
1705
- end
1706
648
 
1707
649
  # Get promo code
1708
- # Get information about a specific promo code.
1709
- # @param store_id The store id.
1710
- # @param promo_rule_id The id for the promo rule of a store.
1711
- # @param promo_code_id The id for the promo code of a store.
1712
- # @param [Hash] opts the optional parameters
1713
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1714
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1715
- # @return [Array<(EcommercePromoCode, Fixnum, Hash)>] EcommercePromoCode data, response status code and response headers
1716
- def get_promo_code_with_http_info(store_id, promo_rule_id, promo_code_id, opts = {})
1717
- # resource path
1718
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes/{promo_code_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'promo_code_id' + '}', promo_code_id.to_s)
650
+ def get_promo_code(store_id, promo_rule_id, promo_code_id, opts = {})
651
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
652
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
653
+ fail ArgumentError, "Missing required param: 'promo_code_id'" if promo_code_id.nil?
1719
654
 
1720
- # query parameters
1721
655
  query_params = {}
1722
656
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1723
657
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1724
-
1725
- # header parameters
1726
- header_params = {}
1727
- # HTTP header 'Accept' (if needed)
1728
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1729
- # HTTP header 'Content-Type'
1730
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1731
-
1732
- # form parameters
1733
658
  form_params = {}
1734
-
1735
- # http body (model)
1736
659
  post_body = nil
1737
- auth_names = ['basicAuth']
660
+
661
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes/{promo_code_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'promo_code_id' + '}', promo_code_id.to_s)
1738
662
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1739
- :header_params => header_params,
1740
663
  :query_params => query_params,
1741
664
  :form_params => form_params,
1742
- :body => post_body,
1743
- :auth_names => auth_names,
1744
- :return_type => 'EcommercePromoCode')
665
+ :body => post_body)
1745
666
  return data, status_code, headers
1746
667
  end
1747
- # List promo rules
1748
- # Get information about a store's promo rules.
1749
- # @param store_id The store id.
1750
- # @param [Hash] opts the optional parameters
1751
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1752
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1753
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000** (default to 10)
1754
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**. (default to 0)
1755
- # @return [PromoRules]
1756
- def list_promo_rules(store_id = {}, opts = {})
1757
- data, _status_code, _headers = list_promo_rules_with_http_info(store_id, opts)
1758
- data
1759
- end
1760
668
 
1761
669
  # List promo rules
1762
- # Get information about a store&#39;s promo rules.
1763
- # @param store_id The store id.
1764
- # @param [Hash] opts the optional parameters
1765
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1766
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1767
- # @option opts [Integer] :count The number of records to return. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **10**. [Maximum value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **1000**
1768
- # @option opts [Integer] :offset The number of records from a collection to skip. Iterating over large collections with this parameter can be slow. [Default value](/developer/guides/get-started-with-mailchimp-api-3/#Parameters) is **0**.
1769
- # @return [Array<(PromoRules, Fixnum, Hash)>] PromoRules data, response status code and response headers
1770
- def list_promo_rules_with_http_info(store_id, opts = {})
1771
- # resource path
1772
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules'.sub('{' + 'store_id' + '}', store_id.to_s)
670
+ def list_promo_rules(store_id, opts = {})
671
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
672
+ fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
1773
673
 
1774
- # query parameters
1775
674
  query_params = {}
1776
675
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1777
676
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1778
677
  query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
1779
678
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
1780
-
1781
- # header parameters
1782
- header_params = {}
1783
- # HTTP header 'Accept' (if needed)
1784
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1785
- # HTTP header 'Content-Type'
1786
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1787
-
1788
- # form parameters
1789
679
  form_params = {}
1790
-
1791
- # http body (model)
1792
680
  post_body = nil
1793
- auth_names = ['basicAuth']
681
+
682
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules'.sub('{' + 'store_id' + '}', store_id.to_s)
1794
683
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1795
- :header_params => header_params,
1796
684
  :query_params => query_params,
1797
685
  :form_params => form_params,
1798
- :body => post_body,
1799
- :auth_names => auth_names,
1800
- :return_type => 'PromoRules')
686
+ :body => post_body)
1801
687
  return data, status_code, headers
1802
688
  end
1803
- # Get promo rule
1804
- # Get information about a specific promo rule.
1805
- # @param store_id The store id.
1806
- # @param promo_rule_id The id for the promo rule of a store.
1807
- # @param [Hash] opts the optional parameters
1808
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1809
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1810
- # @return [EcommercePromoRule]
1811
- def get_promo_rule(store_id = {}, promo_rule_id = {}, opts = {})
1812
- data, _status_code, _headers = get_promo_rule_with_http_info(store_id, promo_rule_id, opts)
1813
- data
1814
- end
1815
689
 
1816
690
  # Get promo rule
1817
- # Get information about a specific promo rule.
1818
- # @param store_id The store id.
1819
- # @param promo_rule_id The id for the promo rule of a store.
1820
- # @param [Hash] opts the optional parameters
1821
- # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1822
- # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1823
- # @return [Array<(EcommercePromoRule, Fixnum, Hash)>] EcommercePromoRule data, response status code and response headers
1824
- def get_promo_rule_with_http_info(store_id, promo_rule_id, opts = {})
1825
- # resource path
1826
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
691
+ def get_promo_rule(store_id, promo_rule_id, opts = {})
692
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
693
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
1827
694
 
1828
- # query parameters
1829
695
  query_params = {}
1830
696
  query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1831
697
  query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1832
-
1833
- # header parameters
1834
- header_params = {}
1835
- # HTTP header 'Accept' (if needed)
1836
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1837
- # HTTP header 'Content-Type'
1838
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1839
-
1840
- # form parameters
1841
698
  form_params = {}
1842
-
1843
- # http body (model)
1844
699
  post_body = nil
1845
- auth_names = ['basicAuth']
700
+
701
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
1846
702
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1847
- :header_params => header_params,
1848
703
  :query_params => query_params,
1849
704
  :form_params => form_params,
1850
- :body => post_body,
1851
- :auth_names => auth_names,
1852
- :return_type => 'EcommercePromoRule')
705
+ :body => post_body)
1853
706
  return data, status_code, headers
1854
707
  end
1855
- # Update store
1856
- # Update a store.
1857
- # @param store_id The store id.
1858
- # @param body
1859
- # @param [Hash] opts the optional parameters
1860
- # @return [EcommerceStore]
1861
- def update_store(store_id = {}, body = {}, opts = {})
1862
- data, _status_code, _headers = update_store_with_http_info(store_id, body, opts)
1863
- data
1864
- end
1865
708
 
1866
709
  # Update store
1867
- # Update a store.
1868
- # @param store_id The store id.
1869
- # @param body
1870
- # @param [Hash] opts the optional parameters
1871
- # @return [Array<(EcommerceStore, Fixnum, Hash)>] EcommerceStore data, response status code and response headers
1872
- def update_store_with_http_info(store_id, body, opts = {})
1873
- # resource path
1874
- local_var_path = '/ecommerce/stores/{store_id}'.sub('{' + 'store_id' + '}', store_id.to_s)
710
+ def update_store(store_id, body, opts = {})
711
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
712
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
1875
713
 
1876
- # query parameters
1877
714
  query_params = {}
1878
-
1879
- # header parameters
1880
- header_params = {}
1881
- # HTTP header 'Accept' (if needed)
1882
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1883
- # HTTP header 'Content-Type'
1884
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1885
-
1886
- # form parameters
1887
715
  form_params = {}
1888
-
1889
- # http body (model)
1890
716
  post_body = @api_client.object_to_http_body(body)
1891
- auth_names = ['basicAuth']
717
+
718
+ local_var_path = '/ecommerce/stores/{store_id}'.sub('{' + 'store_id' + '}', store_id.to_s)
1892
719
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
1893
- :header_params => header_params,
1894
720
  :query_params => query_params,
1895
721
  :form_params => form_params,
1896
- :body => post_body,
1897
- :auth_names => auth_names,
1898
- :return_type => 'EcommerceStore')
722
+ :body => post_body)
1899
723
  return data, status_code, headers
1900
724
  end
1901
- # Update cart
1902
- # Update a specific cart.
1903
- # @param store_id The store id.
1904
- # @param cart_id The id for the cart.
1905
- # @param body
1906
- # @param [Hash] opts the optional parameters
1907
- # @return [EcommerceCart]
1908
- def update_store_cart(store_id = {}, cart_id = {}, body = {}, opts = {})
1909
- data, _status_code, _headers = update_store_cart_with_http_info(store_id, cart_id, body, opts)
1910
- data
1911
- end
1912
725
 
1913
726
  # Update cart
1914
- # Update a specific cart.
1915
- # @param store_id The store id.
1916
- # @param cart_id The id for the cart.
1917
- # @param body
1918
- # @param [Hash] opts the optional parameters
1919
- # @return [Array<(EcommerceCart, Fixnum, Hash)>] EcommerceCart data, response status code and response headers
1920
- def update_store_cart_with_http_info(store_id, cart_id, body, opts = {})
1921
- # resource path
1922
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
727
+ def update_store_cart(store_id, cart_id, body, opts = {})
728
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
729
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
730
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
1923
731
 
1924
- # query parameters
1925
732
  query_params = {}
1926
-
1927
- # header parameters
1928
- header_params = {}
1929
- # HTTP header 'Accept' (if needed)
1930
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1931
- # HTTP header 'Content-Type'
1932
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1933
-
1934
- # form parameters
1935
733
  form_params = {}
1936
-
1937
- # http body (model)
1938
734
  post_body = @api_client.object_to_http_body(body)
1939
- auth_names = ['basicAuth']
735
+
736
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
1940
737
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
1941
- :header_params => header_params,
1942
738
  :query_params => query_params,
1943
739
  :form_params => form_params,
1944
- :body => post_body,
1945
- :auth_names => auth_names,
1946
- :return_type => 'EcommerceCart')
740
+ :body => post_body)
1947
741
  return data, status_code, headers
1948
742
  end
1949
- # Update cart line item
1950
- # Update a specific cart line item.
1951
- # @param store_id The store id.
1952
- # @param cart_id The id for the cart.
1953
- # @param line_id The id for the line item of a cart.
1954
- # @param body
1955
- # @param [Hash] opts the optional parameters
1956
- # @return [EcommerceCartLineItem]
1957
- def update_cart_line_item(store_id = {}, cart_id = {}, line_id = {}, body = {}, opts = {})
1958
- data, _status_code, _headers = update_cart_line_item_with_http_info(store_id, cart_id, line_id, body, opts)
1959
- data
1960
- end
1961
743
 
1962
744
  # Update cart line item
1963
- # Update a specific cart line item.
1964
- # @param store_id The store id.
1965
- # @param cart_id The id for the cart.
1966
- # @param line_id The id for the line item of a cart.
1967
- # @param body
1968
- # @param [Hash] opts the optional parameters
1969
- # @return [Array<(EcommerceCartLineItem, Fixnum, Hash)>] EcommerceCartLineItem data, response status code and response headers
1970
- def update_cart_line_item_with_http_info(store_id, cart_id, line_id, body, opts = {})
1971
- # resource path
1972
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
745
+ def update_cart_line_item(store_id, cart_id, line_id, body, opts = {})
746
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
747
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
748
+ fail ArgumentError, "Missing required param: 'line_id'" if line_id.nil?
749
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
1973
750
 
1974
- # query parameters
1975
751
  query_params = {}
1976
-
1977
- # header parameters
1978
- header_params = {}
1979
- # HTTP header 'Accept' (if needed)
1980
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1981
- # HTTP header 'Content-Type'
1982
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1983
-
1984
- # form parameters
1985
752
  form_params = {}
1986
-
1987
- # http body (model)
1988
753
  post_body = @api_client.object_to_http_body(body)
1989
- auth_names = ['basicAuth']
754
+
755
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
1990
756
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
1991
- :header_params => header_params,
1992
757
  :query_params => query_params,
1993
758
  :form_params => form_params,
1994
- :body => post_body,
1995
- :auth_names => auth_names,
1996
- :return_type => 'EcommerceCartLineItem')
759
+ :body => post_body)
1997
760
  return data, status_code, headers
1998
761
  end
1999
- # Update customer
2000
- # Update a customer.
2001
- # @param store_id The store id.
2002
- # @param customer_id The id for the customer of a store.
2003
- # @param body
2004
- # @param [Hash] opts the optional parameters
2005
- # @return [EcommerceCustomer]
2006
- def update_store_customer(store_id = {}, customer_id = {}, body = {}, opts = {})
2007
- data, _status_code, _headers = update_store_customer_with_http_info(store_id, customer_id, body, opts)
2008
- data
2009
- end
2010
762
 
2011
763
  # Update customer
2012
- # Update a customer.
2013
- # @param store_id The store id.
2014
- # @param customer_id The id for the customer of a store.
2015
- # @param body
2016
- # @param [Hash] opts the optional parameters
2017
- # @return [Array<(EcommerceCustomer, Fixnum, Hash)>] EcommerceCustomer data, response status code and response headers
2018
- def update_store_customer_with_http_info(store_id, customer_id, body, opts = {})
2019
- # resource path
2020
- local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
764
+ def update_store_customer(store_id, customer_id, body, opts = {})
765
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
766
+ fail ArgumentError, "Missing required param: 'customer_id'" if customer_id.nil?
767
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2021
768
 
2022
- # query parameters
2023
769
  query_params = {}
2024
-
2025
- # header parameters
2026
- header_params = {}
2027
- # HTTP header 'Accept' (if needed)
2028
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2029
- # HTTP header 'Content-Type'
2030
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2031
-
2032
- # form parameters
2033
770
  form_params = {}
2034
-
2035
- # http body (model)
2036
771
  post_body = @api_client.object_to_http_body(body)
2037
- auth_names = ['basicAuth']
772
+
773
+ local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
2038
774
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2039
- :header_params => header_params,
2040
775
  :query_params => query_params,
2041
776
  :form_params => form_params,
2042
- :body => post_body,
2043
- :auth_names => auth_names,
2044
- :return_type => 'EcommerceCustomer')
777
+ :body => post_body)
2045
778
  return data, status_code, headers
2046
779
  end
2047
- # Update order
2048
- # Update a specific order.
2049
- # @param store_id The store id.
2050
- # @param order_id The id for the order in a store.
2051
- # @param body
2052
- # @param [Hash] opts the optional parameters
2053
- # @return [EcommerceOrder]
2054
- def update_order(store_id = {}, order_id = {}, body = {}, opts = {})
2055
- data, _status_code, _headers = update_order_with_http_info(store_id, order_id, body, opts)
2056
- data
2057
- end
2058
780
 
2059
781
  # Update order
2060
- # Update a specific order.
2061
- # @param store_id The store id.
2062
- # @param order_id The id for the order in a store.
2063
- # @param body
2064
- # @param [Hash] opts the optional parameters
2065
- # @return [Array<(EcommerceOrder, Fixnum, Hash)>] EcommerceOrder data, response status code and response headers
2066
- def update_order_with_http_info(store_id, order_id, body, opts = {})
2067
- # resource path
2068
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
782
+ def update_order(store_id, order_id, body, opts = {})
783
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
784
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
785
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2069
786
 
2070
- # query parameters
2071
787
  query_params = {}
2072
-
2073
- # header parameters
2074
- header_params = {}
2075
- # HTTP header 'Accept' (if needed)
2076
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2077
- # HTTP header 'Content-Type'
2078
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2079
-
2080
- # form parameters
2081
788
  form_params = {}
2082
-
2083
- # http body (model)
2084
789
  post_body = @api_client.object_to_http_body(body)
2085
- auth_names = ['basicAuth']
790
+
791
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
2086
792
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2087
- :header_params => header_params,
2088
793
  :query_params => query_params,
2089
794
  :form_params => form_params,
2090
- :body => post_body,
2091
- :auth_names => auth_names,
2092
- :return_type => 'EcommerceOrder')
795
+ :body => post_body)
2093
796
  return data, status_code, headers
2094
797
  end
2095
- # Update order line item
2096
- # Update a specific order line item.
2097
- # @param store_id The store id.
2098
- # @param order_id The id for the order in a store.
2099
- # @param line_id The id for the line item of an order.
2100
- # @param body
2101
- # @param [Hash] opts the optional parameters
2102
- # @return [EcommerceOrderLineItem]
2103
- def update_order_line_item(store_id = {}, order_id = {}, line_id = {}, body = {}, opts = {})
2104
- data, _status_code, _headers = update_order_line_item_with_http_info(store_id, order_id, line_id, body, opts)
2105
- data
2106
- end
2107
798
 
2108
799
  # Update order line item
2109
- # Update a specific order line item.
2110
- # @param store_id The store id.
2111
- # @param order_id The id for the order in a store.
2112
- # @param line_id The id for the line item of an order.
2113
- # @param body
2114
- # @param [Hash] opts the optional parameters
2115
- # @return [Array<(EcommerceOrderLineItem, Fixnum, Hash)>] EcommerceOrderLineItem data, response status code and response headers
2116
- def update_order_line_item_with_http_info(store_id, order_id, line_id, body, opts = {})
2117
- # resource path
2118
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
800
+ def update_order_line_item(store_id, order_id, line_id, body, opts = {})
801
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
802
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
803
+ fail ArgumentError, "Missing required param: 'line_id'" if line_id.nil?
804
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2119
805
 
2120
- # query parameters
2121
806
  query_params = {}
2122
-
2123
- # header parameters
2124
- header_params = {}
2125
- # HTTP header 'Accept' (if needed)
2126
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2127
- # HTTP header 'Content-Type'
2128
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2129
-
2130
- # form parameters
2131
807
  form_params = {}
2132
-
2133
- # http body (model)
2134
808
  post_body = @api_client.object_to_http_body(body)
2135
- auth_names = ['basicAuth']
809
+
810
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines/{line_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s).sub('{' + 'line_id' + '}', line_id.to_s)
2136
811
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2137
- :header_params => header_params,
2138
812
  :query_params => query_params,
2139
813
  :form_params => form_params,
2140
- :body => post_body,
2141
- :auth_names => auth_names,
2142
- :return_type => 'EcommerceOrderLineItem')
814
+ :body => post_body)
2143
815
  return data, status_code, headers
2144
816
  end
2145
- # Update product
2146
- # Update a specific product.
2147
- # @param store_id The store id.
2148
- # @param product_id The id for the product of a store.
2149
- # @param body
2150
- # @param [Hash] opts the optional parameters
2151
- # @return [EcommerceProduct]
2152
- def update_store_product(store_id = {}, product_id = {}, body = {}, opts = {})
2153
- data, _status_code, _headers = update_store_product_with_http_info(store_id, product_id, body, opts)
2154
- data
2155
- end
2156
817
 
2157
818
  # Update product
2158
- # Update a specific product.
2159
- # @param store_id The store id.
2160
- # @param product_id The id for the product of a store.
2161
- # @param body
2162
- # @param [Hash] opts the optional parameters
2163
- # @return [Array<(EcommerceProduct, Fixnum, Hash)>] EcommerceProduct data, response status code and response headers
2164
- def update_store_product_with_http_info(store_id, product_id, body, opts = {})
2165
- # resource path
2166
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
819
+ def update_store_product(store_id, product_id, body, opts = {})
820
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
821
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
822
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2167
823
 
2168
- # query parameters
2169
824
  query_params = {}
2170
-
2171
- # header parameters
2172
- header_params = {}
2173
- # HTTP header 'Accept' (if needed)
2174
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2175
- # HTTP header 'Content-Type'
2176
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2177
-
2178
- # form parameters
2179
825
  form_params = {}
2180
-
2181
- # http body (model)
2182
826
  post_body = @api_client.object_to_http_body(body)
2183
- auth_names = ['basicAuth']
827
+
828
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
2184
829
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2185
- :header_params => header_params,
2186
830
  :query_params => query_params,
2187
831
  :form_params => form_params,
2188
- :body => post_body,
2189
- :auth_names => auth_names,
2190
- :return_type => 'EcommerceProduct')
832
+ :body => post_body)
2191
833
  return data, status_code, headers
2192
834
  end
2193
- # Update product image
2194
- # Update a product image.
2195
- # @param store_id The store id.
2196
- # @param product_id The id for the product of a store.
2197
- # @param image_id The id for the product image.
2198
- # @param body
2199
- # @param [Hash] opts the optional parameters
2200
- # @return [EcommerceProductImage]
2201
- def update_product_image(store_id = {}, product_id = {}, image_id = {}, body = {}, opts = {})
2202
- data, _status_code, _headers = update_product_image_with_http_info(store_id, product_id, image_id, body, opts)
2203
- data
2204
- end
2205
835
 
2206
836
  # Update product image
2207
- # Update a product image.
2208
- # @param store_id The store id.
2209
- # @param product_id The id for the product of a store.
2210
- # @param image_id The id for the product image.
2211
- # @param body
2212
- # @param [Hash] opts the optional parameters
2213
- # @return [Array<(EcommerceProductImage, Fixnum, Hash)>] EcommerceProductImage data, response status code and response headers
2214
- def update_product_image_with_http_info(store_id, product_id, image_id, body, opts = {})
2215
- # resource path
2216
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images/{image_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'image_id' + '}', image_id.to_s)
837
+ def update_product_image(store_id, product_id, image_id, body, opts = {})
838
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
839
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
840
+ fail ArgumentError, "Missing required param: 'image_id'" if image_id.nil?
841
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2217
842
 
2218
- # query parameters
2219
843
  query_params = {}
2220
-
2221
- # header parameters
2222
- header_params = {}
2223
- # HTTP header 'Accept' (if needed)
2224
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2225
- # HTTP header 'Content-Type'
2226
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2227
-
2228
- # form parameters
2229
844
  form_params = {}
2230
-
2231
- # http body (model)
2232
845
  post_body = @api_client.object_to_http_body(body)
2233
- auth_names = ['basicAuth']
846
+
847
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images/{image_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'image_id' + '}', image_id.to_s)
2234
848
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2235
- :header_params => header_params,
2236
849
  :query_params => query_params,
2237
850
  :form_params => form_params,
2238
- :body => post_body,
2239
- :auth_names => auth_names,
2240
- :return_type => 'EcommerceProductImage')
851
+ :body => post_body)
2241
852
  return data, status_code, headers
2242
853
  end
2243
- # Update product variant
2244
- # Update a product variant.
2245
- # @param store_id The store id.
2246
- # @param product_id The id for the product of a store.
2247
- # @param variant_id The id for the product variant.
2248
- # @param body
2249
- # @param [Hash] opts the optional parameters
2250
- # @return [EcommerceProductVariant]
2251
- def update_product_variant(store_id = {}, product_id = {}, variant_id = {}, body = {}, opts = {})
2252
- data, _status_code, _headers = update_product_variant_with_http_info(store_id, product_id, variant_id, body, opts)
2253
- data
2254
- end
2255
854
 
2256
855
  # Update product variant
2257
- # Update a product variant.
2258
- # @param store_id The store id.
2259
- # @param product_id The id for the product of a store.
2260
- # @param variant_id The id for the product variant.
2261
- # @param body
2262
- # @param [Hash] opts the optional parameters
2263
- # @return [Array<(EcommerceProductVariant, Fixnum, Hash)>] EcommerceProductVariant data, response status code and response headers
2264
- def update_product_variant_with_http_info(store_id, product_id, variant_id, body, opts = {})
2265
- # resource path
2266
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
856
+ def update_product_variant(store_id, product_id, variant_id, body, opts = {})
857
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
858
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
859
+ fail ArgumentError, "Missing required param: 'variant_id'" if variant_id.nil?
860
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2267
861
 
2268
- # query parameters
2269
862
  query_params = {}
2270
-
2271
- # header parameters
2272
- header_params = {}
2273
- # HTTP header 'Accept' (if needed)
2274
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2275
- # HTTP header 'Content-Type'
2276
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2277
-
2278
- # form parameters
2279
863
  form_params = {}
2280
-
2281
- # http body (model)
2282
864
  post_body = @api_client.object_to_http_body(body)
2283
- auth_names = ['basicAuth']
865
+
866
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
2284
867
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2285
- :header_params => header_params,
2286
868
  :query_params => query_params,
2287
869
  :form_params => form_params,
2288
- :body => post_body,
2289
- :auth_names => auth_names,
2290
- :return_type => 'EcommerceProductVariant')
870
+ :body => post_body)
2291
871
  return data, status_code, headers
2292
872
  end
2293
- # Update promo code
2294
- # Update a promo code.
2295
- # @param store_id The store id.
2296
- # @param promo_rule_id The id for the promo rule of a store.
2297
- # @param promo_code_id The id for the promo code of a store.
2298
- # @param body
2299
- # @param [Hash] opts the optional parameters
2300
- # @return [EcommercePromoCode]
2301
- def update_promo_code(store_id = {}, promo_rule_id = {}, promo_code_id = {}, body = {}, opts = {})
2302
- data, _status_code, _headers = update_promo_code_with_http_info(store_id, promo_rule_id, promo_code_id, body, opts)
2303
- data
2304
- end
2305
873
 
2306
874
  # Update promo code
2307
- # Update a promo code.
2308
- # @param store_id The store id.
2309
- # @param promo_rule_id The id for the promo rule of a store.
2310
- # @param promo_code_id The id for the promo code of a store.
2311
- # @param body
2312
- # @param [Hash] opts the optional parameters
2313
- # @return [Array<(EcommercePromoCode, Fixnum, Hash)>] EcommercePromoCode data, response status code and response headers
2314
- def update_promo_code_with_http_info(store_id, promo_rule_id, promo_code_id, body, opts = {})
2315
- # resource path
2316
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes/{promo_code_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'promo_code_id' + '}', promo_code_id.to_s)
875
+ def update_promo_code(store_id, promo_rule_id, promo_code_id, body, opts = {})
876
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
877
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
878
+ fail ArgumentError, "Missing required param: 'promo_code_id'" if promo_code_id.nil?
879
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2317
880
 
2318
- # query parameters
2319
881
  query_params = {}
2320
-
2321
- # header parameters
2322
- header_params = {}
2323
- # HTTP header 'Accept' (if needed)
2324
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2325
- # HTTP header 'Content-Type'
2326
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2327
-
2328
- # form parameters
2329
882
  form_params = {}
2330
-
2331
- # http body (model)
2332
883
  post_body = @api_client.object_to_http_body(body)
2333
- auth_names = ['basicAuth']
884
+
885
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes/{promo_code_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s).sub('{' + 'promo_code_id' + '}', promo_code_id.to_s)
2334
886
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2335
- :header_params => header_params,
2336
887
  :query_params => query_params,
2337
888
  :form_params => form_params,
2338
- :body => post_body,
2339
- :auth_names => auth_names,
2340
- :return_type => 'EcommercePromoCode')
889
+ :body => post_body)
2341
890
  return data, status_code, headers
2342
891
  end
2343
- # Update promo rule
2344
- # Update a promo rule.
2345
- # @param store_id The store id.
2346
- # @param promo_rule_id The id for the promo rule of a store.
2347
- # @param body
2348
- # @param [Hash] opts the optional parameters
2349
- # @return [EcommercePromoRule]
2350
- def update_promo_rule(store_id = {}, promo_rule_id = {}, body = {}, opts = {})
2351
- data, _status_code, _headers = update_promo_rule_with_http_info(store_id, promo_rule_id, body, opts)
2352
- data
2353
- end
2354
892
 
2355
893
  # Update promo rule
2356
- # Update a promo rule.
2357
- # @param store_id The store id.
2358
- # @param promo_rule_id The id for the promo rule of a store.
2359
- # @param body
2360
- # @param [Hash] opts the optional parameters
2361
- # @return [Array<(EcommercePromoRule, Fixnum, Hash)>] EcommercePromoRule data, response status code and response headers
2362
- def update_promo_rule_with_http_info(store_id, promo_rule_id, body, opts = {})
2363
- # resource path
2364
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
894
+ def update_promo_rule(store_id, promo_rule_id, body, opts = {})
895
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
896
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
897
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2365
898
 
2366
- # query parameters
2367
899
  query_params = {}
2368
-
2369
- # header parameters
2370
- header_params = {}
2371
- # HTTP header 'Accept' (if needed)
2372
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2373
- # HTTP header 'Content-Type'
2374
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2375
-
2376
- # form parameters
2377
900
  form_params = {}
2378
-
2379
- # http body (model)
2380
901
  post_body = @api_client.object_to_http_body(body)
2381
- auth_names = ['basicAuth']
902
+
903
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
2382
904
  data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
2383
- :header_params => header_params,
2384
905
  :query_params => query_params,
2385
906
  :form_params => form_params,
2386
- :body => post_body,
2387
- :auth_names => auth_names,
2388
- :return_type => 'EcommercePromoRule')
907
+ :body => post_body)
2389
908
  return data, status_code, headers
2390
909
  end
2391
- # Add store
2392
- # Add a new store to your Mailchimp account.
2393
- # @param body
2394
- # @param [Hash] opts the optional parameters
2395
- # @return [EcommerceStore]
2396
- def add_store(body = {}, opts = {})
2397
- data, _status_code, _headers = add_store_with_http_info(body, opts)
2398
- data
2399
- end
2400
910
 
2401
911
  # Add store
2402
- # Add a new store to your Mailchimp account.
2403
- # @param body
2404
- # @param [Hash] opts the optional parameters
2405
- # @return [Array<(EcommerceStore, Fixnum, Hash)>] EcommerceStore data, response status code and response headers
2406
- def add_store_with_http_info(body, opts = {})
2407
- # resource path
2408
- local_var_path = '/ecommerce/stores'
912
+ def add_store(body, opts = {})
913
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2409
914
 
2410
- # query parameters
2411
915
  query_params = {}
2412
-
2413
- # header parameters
2414
- header_params = {}
2415
- # HTTP header 'Accept' (if needed)
2416
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2417
- # HTTP header 'Content-Type'
2418
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2419
-
2420
- # form parameters
2421
916
  form_params = {}
2422
-
2423
- # http body (model)
2424
917
  post_body = @api_client.object_to_http_body(body)
2425
- auth_names = ['basicAuth']
918
+
919
+ local_var_path = '/ecommerce/stores'
2426
920
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2427
- :header_params => header_params,
2428
921
  :query_params => query_params,
2429
922
  :form_params => form_params,
2430
- :body => post_body,
2431
- :auth_names => auth_names,
2432
- :return_type => 'EcommerceStore')
923
+ :body => post_body)
2433
924
  return data, status_code, headers
2434
925
  end
2435
- # Add cart
2436
- # Add a new cart to a store.
2437
- # @param store_id The store id.
2438
- # @param body
2439
- # @param [Hash] opts the optional parameters
2440
- # @return [EcommerceCart]
2441
- def add_store_cart(store_id = {}, body = {}, opts = {})
2442
- data, _status_code, _headers = add_store_cart_with_http_info(store_id, body, opts)
2443
- data
2444
- end
2445
926
 
2446
927
  # Add cart
2447
- # Add a new cart to a store.
2448
- # @param store_id The store id.
2449
- # @param body
2450
- # @param [Hash] opts the optional parameters
2451
- # @return [Array<(EcommerceCart, Fixnum, Hash)>] EcommerceCart data, response status code and response headers
2452
- def add_store_cart_with_http_info(store_id, body, opts = {})
2453
- # resource path
2454
- local_var_path = '/ecommerce/stores/{store_id}/carts'.sub('{' + 'store_id' + '}', store_id.to_s)
928
+ def add_store_cart(store_id, body, opts = {})
929
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
930
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2455
931
 
2456
- # query parameters
2457
932
  query_params = {}
2458
-
2459
- # header parameters
2460
- header_params = {}
2461
- # HTTP header 'Accept' (if needed)
2462
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2463
- # HTTP header 'Content-Type'
2464
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2465
-
2466
- # form parameters
2467
933
  form_params = {}
2468
-
2469
- # http body (model)
2470
934
  post_body = @api_client.object_to_http_body(body)
2471
- auth_names = ['basicAuth']
935
+
936
+ local_var_path = '/ecommerce/stores/{store_id}/carts'.sub('{' + 'store_id' + '}', store_id.to_s)
2472
937
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2473
- :header_params => header_params,
2474
938
  :query_params => query_params,
2475
939
  :form_params => form_params,
2476
- :body => post_body,
2477
- :auth_names => auth_names,
2478
- :return_type => 'EcommerceCart')
940
+ :body => post_body)
2479
941
  return data, status_code, headers
2480
942
  end
2481
- # Add cart line item
2482
- # Add a new line item to an existing cart.
2483
- # @param store_id The store id.
2484
- # @param cart_id The id for the cart.
2485
- # @param body
2486
- # @param [Hash] opts the optional parameters
2487
- # @return [EcommerceCartLineItem]
2488
- def add_cart_line_item(store_id = {}, cart_id = {}, body = {}, opts = {})
2489
- data, _status_code, _headers = add_cart_line_item_with_http_info(store_id, cart_id, body, opts)
2490
- data
2491
- end
2492
943
 
2493
944
  # Add cart line item
2494
- # Add a new line item to an existing cart.
2495
- # @param store_id The store id.
2496
- # @param cart_id The id for the cart.
2497
- # @param body
2498
- # @param [Hash] opts the optional parameters
2499
- # @return [Array<(EcommerceCartLineItem, Fixnum, Hash)>] EcommerceCartLineItem data, response status code and response headers
2500
- def add_cart_line_item_with_http_info(store_id, cart_id, body, opts = {})
2501
- # resource path
2502
- local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
945
+ def add_cart_line_item(store_id, cart_id, body, opts = {})
946
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
947
+ fail ArgumentError, "Missing required param: 'cart_id'" if cart_id.nil?
948
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2503
949
 
2504
- # query parameters
2505
950
  query_params = {}
2506
-
2507
- # header parameters
2508
- header_params = {}
2509
- # HTTP header 'Accept' (if needed)
2510
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2511
- # HTTP header 'Content-Type'
2512
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2513
-
2514
- # form parameters
2515
951
  form_params = {}
2516
-
2517
- # http body (model)
2518
952
  post_body = @api_client.object_to_http_body(body)
2519
- auth_names = ['basicAuth']
953
+
954
+ local_var_path = '/ecommerce/stores/{store_id}/carts/{cart_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'cart_id' + '}', cart_id.to_s)
2520
955
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2521
- :header_params => header_params,
2522
956
  :query_params => query_params,
2523
957
  :form_params => form_params,
2524
- :body => post_body,
2525
- :auth_names => auth_names,
2526
- :return_type => 'EcommerceCartLineItem')
958
+ :body => post_body)
2527
959
  return data, status_code, headers
2528
960
  end
2529
- # Add customer
2530
- # Add a new customer to a store.
2531
- # @param store_id The store id.
2532
- # @param body
2533
- # @param [Hash] opts the optional parameters
2534
- # @return [EcommerceCustomer]
2535
- def add_store_customer(store_id = {}, body = {}, opts = {})
2536
- data, _status_code, _headers = add_store_customer_with_http_info(store_id, body, opts)
2537
- data
2538
- end
2539
961
 
2540
962
  # Add customer
2541
- # Add a new customer to a store.
2542
- # @param store_id The store id.
2543
- # @param body
2544
- # @param [Hash] opts the optional parameters
2545
- # @return [Array<(EcommerceCustomer, Fixnum, Hash)>] EcommerceCustomer data, response status code and response headers
2546
- def add_store_customer_with_http_info(store_id, body, opts = {})
2547
- # resource path
2548
- local_var_path = '/ecommerce/stores/{store_id}/customers'.sub('{' + 'store_id' + '}', store_id.to_s)
963
+ def add_store_customer(store_id, body, opts = {})
964
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
965
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2549
966
 
2550
- # query parameters
2551
967
  query_params = {}
2552
-
2553
- # header parameters
2554
- header_params = {}
2555
- # HTTP header 'Accept' (if needed)
2556
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2557
- # HTTP header 'Content-Type'
2558
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2559
-
2560
- # form parameters
2561
968
  form_params = {}
2562
-
2563
- # http body (model)
2564
969
  post_body = @api_client.object_to_http_body(body)
2565
- auth_names = ['basicAuth']
970
+
971
+ local_var_path = '/ecommerce/stores/{store_id}/customers'.sub('{' + 'store_id' + '}', store_id.to_s)
2566
972
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2567
- :header_params => header_params,
2568
973
  :query_params => query_params,
2569
974
  :form_params => form_params,
2570
- :body => post_body,
2571
- :auth_names => auth_names,
2572
- :return_type => 'EcommerceCustomer')
975
+ :body => post_body)
2573
976
  return data, status_code, headers
2574
977
  end
2575
- # Add order
2576
- # Add a new order to a store.
2577
- # @param store_id The store id.
2578
- # @param body
2579
- # @param [Hash] opts the optional parameters
2580
- # @return [EcommerceOrder]
2581
- def add_store_order(store_id = {}, body = {}, opts = {})
2582
- data, _status_code, _headers = add_store_order_with_http_info(store_id, body, opts)
2583
- data
2584
- end
2585
978
 
2586
979
  # Add order
2587
- # Add a new order to a store.
2588
- # @param store_id The store id.
2589
- # @param body
2590
- # @param [Hash] opts the optional parameters
2591
- # @return [Array<(EcommerceOrder, Fixnum, Hash)>] EcommerceOrder data, response status code and response headers
2592
- def add_store_order_with_http_info(store_id, body, opts = {})
2593
- # resource path
2594
- local_var_path = '/ecommerce/stores/{store_id}/orders'.sub('{' + 'store_id' + '}', store_id.to_s)
980
+ def add_store_order(store_id, body, opts = {})
981
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
982
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2595
983
 
2596
- # query parameters
2597
984
  query_params = {}
2598
-
2599
- # header parameters
2600
- header_params = {}
2601
- # HTTP header 'Accept' (if needed)
2602
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2603
- # HTTP header 'Content-Type'
2604
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2605
-
2606
- # form parameters
2607
985
  form_params = {}
2608
-
2609
- # http body (model)
2610
986
  post_body = @api_client.object_to_http_body(body)
2611
- auth_names = ['basicAuth']
987
+
988
+ local_var_path = '/ecommerce/stores/{store_id}/orders'.sub('{' + 'store_id' + '}', store_id.to_s)
2612
989
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2613
- :header_params => header_params,
2614
990
  :query_params => query_params,
2615
991
  :form_params => form_params,
2616
- :body => post_body,
2617
- :auth_names => auth_names,
2618
- :return_type => 'EcommerceOrder')
992
+ :body => post_body)
2619
993
  return data, status_code, headers
2620
994
  end
2621
- # Add order line item
2622
- # Add a new line item to an existing order.
2623
- # @param store_id The store id.
2624
- # @param order_id The id for the order in a store.
2625
- # @param body
2626
- # @param [Hash] opts the optional parameters
2627
- # @return [EcommerceOrderLineItem]
2628
- def add_order_line_item(store_id = {}, order_id = {}, body = {}, opts = {})
2629
- data, _status_code, _headers = add_order_line_item_with_http_info(store_id, order_id, body, opts)
2630
- data
2631
- end
2632
995
 
2633
996
  # Add order line item
2634
- # Add a new line item to an existing order.
2635
- # @param store_id The store id.
2636
- # @param order_id The id for the order in a store.
2637
- # @param body
2638
- # @param [Hash] opts the optional parameters
2639
- # @return [Array<(EcommerceOrderLineItem, Fixnum, Hash)>] EcommerceOrderLineItem data, response status code and response headers
2640
- def add_order_line_item_with_http_info(store_id, order_id, body, opts = {})
2641
- # resource path
2642
- local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
997
+ def add_order_line_item(store_id, order_id, body, opts = {})
998
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
999
+ fail ArgumentError, "Missing required param: 'order_id'" if order_id.nil?
1000
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2643
1001
 
2644
- # query parameters
2645
1002
  query_params = {}
2646
-
2647
- # header parameters
2648
- header_params = {}
2649
- # HTTP header 'Accept' (if needed)
2650
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2651
- # HTTP header 'Content-Type'
2652
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2653
-
2654
- # form parameters
2655
1003
  form_params = {}
2656
-
2657
- # http body (model)
2658
1004
  post_body = @api_client.object_to_http_body(body)
2659
- auth_names = ['basicAuth']
1005
+
1006
+ local_var_path = '/ecommerce/stores/{store_id}/orders/{order_id}/lines'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'order_id' + '}', order_id.to_s)
2660
1007
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2661
- :header_params => header_params,
2662
1008
  :query_params => query_params,
2663
1009
  :form_params => form_params,
2664
- :body => post_body,
2665
- :auth_names => auth_names,
2666
- :return_type => 'EcommerceOrderLineItem')
1010
+ :body => post_body)
2667
1011
  return data, status_code, headers
2668
1012
  end
2669
- # Add product
2670
- # Add a new product to a store.
2671
- # @param store_id The store id.
2672
- # @param body
2673
- # @param [Hash] opts the optional parameters
2674
- # @return [EcommerceProduct]
2675
- def add_store_product(store_id = {}, body = {}, opts = {})
2676
- data, _status_code, _headers = add_store_product_with_http_info(store_id, body, opts)
2677
- data
2678
- end
2679
1013
 
2680
1014
  # Add product
2681
- # Add a new product to a store.
2682
- # @param store_id The store id.
2683
- # @param body
2684
- # @param [Hash] opts the optional parameters
2685
- # @return [Array<(EcommerceProduct, Fixnum, Hash)>] EcommerceProduct data, response status code and response headers
2686
- def add_store_product_with_http_info(store_id, body, opts = {})
2687
- # resource path
2688
- local_var_path = '/ecommerce/stores/{store_id}/products'.sub('{' + 'store_id' + '}', store_id.to_s)
1015
+ def add_store_product(store_id, body, opts = {})
1016
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
1017
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2689
1018
 
2690
- # query parameters
2691
1019
  query_params = {}
2692
-
2693
- # header parameters
2694
- header_params = {}
2695
- # HTTP header 'Accept' (if needed)
2696
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2697
- # HTTP header 'Content-Type'
2698
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2699
-
2700
- # form parameters
2701
1020
  form_params = {}
2702
-
2703
- # http body (model)
2704
1021
  post_body = @api_client.object_to_http_body(body)
2705
- auth_names = ['basicAuth']
1022
+
1023
+ local_var_path = '/ecommerce/stores/{store_id}/products'.sub('{' + 'store_id' + '}', store_id.to_s)
2706
1024
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2707
- :header_params => header_params,
2708
1025
  :query_params => query_params,
2709
1026
  :form_params => form_params,
2710
- :body => post_body,
2711
- :auth_names => auth_names,
2712
- :return_type => 'EcommerceProduct')
1027
+ :body => post_body)
2713
1028
  return data, status_code, headers
2714
1029
  end
2715
- # Add product image
2716
- # Add a new image to the product.
2717
- # @param store_id The store id.
2718
- # @param product_id The id for the product of a store.
2719
- # @param body
2720
- # @param [Hash] opts the optional parameters
2721
- # @return [EcommerceProductImage]
2722
- def add_product_image(store_id = {}, product_id = {}, body = {}, opts = {})
2723
- data, _status_code, _headers = add_product_image_with_http_info(store_id, product_id, body, opts)
2724
- data
2725
- end
2726
1030
 
2727
1031
  # Add product image
2728
- # Add a new image to the product.
2729
- # @param store_id The store id.
2730
- # @param product_id The id for the product of a store.
2731
- # @param body
2732
- # @param [Hash] opts the optional parameters
2733
- # @return [Array<(EcommerceProductImage, Fixnum, Hash)>] EcommerceProductImage data, response status code and response headers
2734
- def add_product_image_with_http_info(store_id, product_id, body, opts = {})
2735
- # resource path
2736
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
1032
+ def add_product_image(store_id, product_id, body, opts = {})
1033
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
1034
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
1035
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2737
1036
 
2738
- # query parameters
2739
1037
  query_params = {}
2740
-
2741
- # header parameters
2742
- header_params = {}
2743
- # HTTP header 'Accept' (if needed)
2744
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2745
- # HTTP header 'Content-Type'
2746
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2747
-
2748
- # form parameters
2749
1038
  form_params = {}
2750
-
2751
- # http body (model)
2752
1039
  post_body = @api_client.object_to_http_body(body)
2753
- auth_names = ['basicAuth']
1040
+
1041
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/images'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
2754
1042
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2755
- :header_params => header_params,
2756
1043
  :query_params => query_params,
2757
1044
  :form_params => form_params,
2758
- :body => post_body,
2759
- :auth_names => auth_names,
2760
- :return_type => 'EcommerceProductImage')
1045
+ :body => post_body)
2761
1046
  return data, status_code, headers
2762
1047
  end
2763
- # Add product variant
2764
- # Add a new variant to the product.
2765
- # @param store_id The store id.
2766
- # @param product_id The id for the product of a store.
2767
- # @param body
2768
- # @param [Hash] opts the optional parameters
2769
- # @return [EcommerceProductVariant]
2770
- def add_product_variants(store_id = {}, product_id = {}, body = {}, opts = {})
2771
- data, _status_code, _headers = add_product_variants_with_http_info(store_id, product_id, body, opts)
2772
- data
2773
- end
2774
1048
 
2775
1049
  # Add product variant
2776
- # Add a new variant to the product.
2777
- # @param store_id The store id.
2778
- # @param product_id The id for the product of a store.
2779
- # @param body
2780
- # @param [Hash] opts the optional parameters
2781
- # @return [Array<(EcommerceProductVariant, Fixnum, Hash)>] EcommerceProductVariant data, response status code and response headers
2782
- def add_product_variants_with_http_info(store_id, product_id, body, opts = {})
2783
- # resource path
2784
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
1050
+ def add_product_variants(store_id, product_id, body, opts = {})
1051
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
1052
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
1053
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2785
1054
 
2786
- # query parameters
2787
1055
  query_params = {}
2788
-
2789
- # header parameters
2790
- header_params = {}
2791
- # HTTP header 'Accept' (if needed)
2792
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2793
- # HTTP header 'Content-Type'
2794
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2795
-
2796
- # form parameters
2797
1056
  form_params = {}
2798
-
2799
- # http body (model)
2800
1057
  post_body = @api_client.object_to_http_body(body)
2801
- auth_names = ['basicAuth']
1058
+
1059
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s)
2802
1060
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2803
- :header_params => header_params,
2804
1061
  :query_params => query_params,
2805
1062
  :form_params => form_params,
2806
- :body => post_body,
2807
- :auth_names => auth_names,
2808
- :return_type => 'EcommerceProductVariant')
1063
+ :body => post_body)
2809
1064
  return data, status_code, headers
2810
1065
  end
2811
- # Add promo code
2812
- # Add a new promo code to a store.
2813
- # @param store_id The store id.
2814
- # @param promo_rule_id The id for the promo rule of a store.
2815
- # @param body
2816
- # @param [Hash] opts the optional parameters
2817
- # @return [EcommercePromoCode]
2818
- def add_promo_code(store_id = {}, promo_rule_id = {}, body = {}, opts = {})
2819
- data, _status_code, _headers = add_promo_code_with_http_info(store_id, promo_rule_id, body, opts)
2820
- data
2821
- end
2822
1066
 
2823
1067
  # Add promo code
2824
- # Add a new promo code to a store.
2825
- # @param store_id The store id.
2826
- # @param promo_rule_id The id for the promo rule of a store.
2827
- # @param body
2828
- # @param [Hash] opts the optional parameters
2829
- # @return [Array<(EcommercePromoCode, Fixnum, Hash)>] EcommercePromoCode data, response status code and response headers
2830
- def add_promo_code_with_http_info(store_id, promo_rule_id, body, opts = {})
2831
- # resource path
2832
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
1068
+ def add_promo_code(store_id, promo_rule_id, body, opts = {})
1069
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
1070
+ fail ArgumentError, "Missing required param: 'promo_rule_id'" if promo_rule_id.nil?
1071
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2833
1072
 
2834
- # query parameters
2835
1073
  query_params = {}
2836
-
2837
- # header parameters
2838
- header_params = {}
2839
- # HTTP header 'Accept' (if needed)
2840
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2841
- # HTTP header 'Content-Type'
2842
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2843
-
2844
- # form parameters
2845
1074
  form_params = {}
2846
-
2847
- # http body (model)
2848
1075
  post_body = @api_client.object_to_http_body(body)
2849
- auth_names = ['basicAuth']
1076
+
1077
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules/{promo_rule_id}/promo-codes'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'promo_rule_id' + '}', promo_rule_id.to_s)
2850
1078
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2851
- :header_params => header_params,
2852
1079
  :query_params => query_params,
2853
1080
  :form_params => form_params,
2854
- :body => post_body,
2855
- :auth_names => auth_names,
2856
- :return_type => 'EcommercePromoCode')
1081
+ :body => post_body)
2857
1082
  return data, status_code, headers
2858
1083
  end
2859
- # Add promo rule
2860
- # Add a new promo rule to a store.
2861
- # @param store_id The store id.
2862
- # @param body
2863
- # @param [Hash] opts the optional parameters
2864
- # @return [EcommercePromoRule]
2865
- def add_promo_rules(store_id = {}, body = {}, opts = {})
2866
- data, _status_code, _headers = add_promo_rules_with_http_info(store_id, body, opts)
2867
- data
2868
- end
2869
1084
 
2870
1085
  # Add promo rule
2871
- # Add a new promo rule to a store.
2872
- # @param store_id The store id.
2873
- # @param body
2874
- # @param [Hash] opts the optional parameters
2875
- # @return [Array<(EcommercePromoRule, Fixnum, Hash)>] EcommercePromoRule data, response status code and response headers
2876
- def add_promo_rules_with_http_info(store_id, body, opts = {})
2877
- # resource path
2878
- local_var_path = '/ecommerce/stores/{store_id}/promo-rules'.sub('{' + 'store_id' + '}', store_id.to_s)
1086
+ def add_promo_rules(store_id, body, opts = {})
1087
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
1088
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2879
1089
 
2880
- # query parameters
2881
1090
  query_params = {}
2882
-
2883
- # header parameters
2884
- header_params = {}
2885
- # HTTP header 'Accept' (if needed)
2886
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2887
- # HTTP header 'Content-Type'
2888
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2889
-
2890
- # form parameters
2891
1091
  form_params = {}
2892
-
2893
- # http body (model)
2894
1092
  post_body = @api_client.object_to_http_body(body)
2895
- auth_names = ['basicAuth']
1093
+
1094
+ local_var_path = '/ecommerce/stores/{store_id}/promo-rules'.sub('{' + 'store_id' + '}', store_id.to_s)
2896
1095
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
2897
- :header_params => header_params,
2898
1096
  :query_params => query_params,
2899
1097
  :form_params => form_params,
2900
- :body => post_body,
2901
- :auth_names => auth_names,
2902
- :return_type => 'EcommercePromoRule')
1098
+ :body => post_body)
2903
1099
  return data, status_code, headers
2904
1100
  end
2905
- # Add or update customer
2906
- # Add or update a customer.
2907
- # @param store_id The store id.
2908
- # @param customer_id The id for the customer of a store.
2909
- # @param body
2910
- # @param [Hash] opts the optional parameters
2911
- # @return [EcommerceCustomer]
2912
- def set_store_customer(store_id = {}, customer_id = {}, body = {}, opts = {})
2913
- data, _status_code, _headers = set_store_customer_with_http_info(store_id, customer_id, body, opts)
2914
- data
2915
- end
2916
1101
 
2917
1102
  # Add or update customer
2918
- # Add or update a customer.
2919
- # @param store_id The store id.
2920
- # @param customer_id The id for the customer of a store.
2921
- # @param body
2922
- # @param [Hash] opts the optional parameters
2923
- # @return [Array<(EcommerceCustomer, Fixnum, Hash)>] EcommerceCustomer data, response status code and response headers
2924
- def set_store_customer_with_http_info(store_id, customer_id, body, opts = {})
2925
- # resource path
2926
- local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
1103
+ def set_store_customer(store_id, customer_id, body, opts = {})
1104
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
1105
+ fail ArgumentError, "Missing required param: 'customer_id'" if customer_id.nil?
1106
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2927
1107
 
2928
- # query parameters
2929
1108
  query_params = {}
2930
-
2931
- # header parameters
2932
- header_params = {}
2933
- # HTTP header 'Accept' (if needed)
2934
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2935
- # HTTP header 'Content-Type'
2936
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2937
-
2938
- # form parameters
2939
1109
  form_params = {}
2940
-
2941
- # http body (model)
2942
1110
  post_body = @api_client.object_to_http_body(body)
2943
- auth_names = ['basicAuth']
1111
+
1112
+ local_var_path = '/ecommerce/stores/{store_id}/customers/{customer_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'customer_id' + '}', customer_id.to_s)
2944
1113
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
2945
- :header_params => header_params,
2946
1114
  :query_params => query_params,
2947
1115
  :form_params => form_params,
2948
- :body => post_body,
2949
- :auth_names => auth_names,
2950
- :return_type => 'EcommerceCustomer')
1116
+ :body => post_body)
2951
1117
  return data, status_code, headers
2952
1118
  end
2953
- # Add or update product variant
2954
- # Add or update a product variant.
2955
- # @param store_id The store id.
2956
- # @param product_id The id for the product of a store.
2957
- # @param variant_id The id for the product variant.
2958
- # @param body
2959
- # @param [Hash] opts the optional parameters
2960
- # @return [EcommerceProductVariant]
2961
- def add_product_variant(store_id = {}, product_id = {}, variant_id = {}, body = {}, opts = {})
2962
- data, _status_code, _headers = add_product_variant_with_http_info(store_id, product_id, variant_id, body, opts)
2963
- data
2964
- end
2965
1119
 
2966
1120
  # Add or update product variant
2967
- # Add or update a product variant.
2968
- # @param store_id The store id.
2969
- # @param product_id The id for the product of a store.
2970
- # @param variant_id The id for the product variant.
2971
- # @param body
2972
- # @param [Hash] opts the optional parameters
2973
- # @return [Array<(EcommerceProductVariant, Fixnum, Hash)>] EcommerceProductVariant data, response status code and response headers
2974
- def add_product_variant_with_http_info(store_id, product_id, variant_id, body, opts = {})
2975
- # resource path
2976
- local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
1121
+ def add_product_variant(store_id, product_id, variant_id, body, opts = {})
1122
+ fail ArgumentError, "Missing required param: 'store_id'" if store_id.nil?
1123
+ fail ArgumentError, "Missing required param: 'product_id'" if product_id.nil?
1124
+ fail ArgumentError, "Missing required param: 'variant_id'" if variant_id.nil?
1125
+ fail ArgumentError, "Missing required param: 'body'" if body.nil?
2977
1126
 
2978
- # query parameters
2979
1127
  query_params = {}
2980
-
2981
- # header parameters
2982
- header_params = {}
2983
- # HTTP header 'Accept' (if needed)
2984
- header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
2985
- # HTTP header 'Content-Type'
2986
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
2987
-
2988
- # form parameters
2989
1128
  form_params = {}
2990
-
2991
- # http body (model)
2992
1129
  post_body = @api_client.object_to_http_body(body)
2993
- auth_names = ['basicAuth']
1130
+
1131
+ local_var_path = '/ecommerce/stores/{store_id}/products/{product_id}/variants/{variant_id}'.sub('{' + 'store_id' + '}', store_id.to_s).sub('{' + 'product_id' + '}', product_id.to_s).sub('{' + 'variant_id' + '}', variant_id.to_s)
2994
1132
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
2995
- :header_params => header_params,
2996
1133
  :query_params => query_params,
2997
1134
  :form_params => form_params,
2998
- :body => post_body,
2999
- :auth_names => auth_names,
3000
- :return_type => 'EcommerceProductVariant')
1135
+ :body => post_body)
3001
1136
  return data, status_code, headers
3002
1137
  end
3003
1138
  end