MailchimpMarketing 3.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +7 -0
  3. data/MailchimpMarketing.gemspec +45 -0
  4. data/README.md +369 -0
  5. data/lib/MailchimpMarketing.rb +163 -0
  6. data/lib/MailchimpMarketing/api/activity_feed_api.rb +113 -0
  7. data/lib/MailchimpMarketing/api/authorized_apps_api.rb +171 -0
  8. data/lib/MailchimpMarketing/api/automations_api.rb +906 -0
  9. data/lib/MailchimpMarketing/api/batch_webhooks_api.rb +260 -0
  10. data/lib/MailchimpMarketing/api/batches_api.rb +214 -0
  11. data/lib/MailchimpMarketing/api/campaign_folders_api.rb +260 -0
  12. data/lib/MailchimpMarketing/api/campaigns_api.rb +1073 -0
  13. data/lib/MailchimpMarketing/api/connected_sites_api.rb +257 -0
  14. data/lib/MailchimpMarketing/api/conversations_api.rb +293 -0
  15. data/lib/MailchimpMarketing/api/dashboard_api.rb +317 -0
  16. data/lib/MailchimpMarketing/api/ecommerce_api.rb +3004 -0
  17. data/lib/MailchimpMarketing/api/external_auths_api.rb +171 -0
  18. data/lib/MailchimpMarketing/api/facebook_ads_api.rb +133 -0
  19. data/lib/MailchimpMarketing/api/file_manager_api.rb +566 -0
  20. data/lib/MailchimpMarketing/api/landing_pages_api.rb +399 -0
  21. data/lib/MailchimpMarketing/api/lists_api.rb +3457 -0
  22. data/lib/MailchimpMarketing/api/ping_api.rb +65 -0
  23. data/lib/MailchimpMarketing/api/postcards_api.rb +77 -0
  24. data/lib/MailchimpMarketing/api/reporting_api.rb +338 -0
  25. data/lib/MailchimpMarketing/api/reports_api.rb +1214 -0
  26. data/lib/MailchimpMarketing/api/root_api.rb +71 -0
  27. data/lib/MailchimpMarketing/api/search_campaigns_api.rb +74 -0
  28. data/lib/MailchimpMarketing/api/search_members_api.rb +77 -0
  29. data/lib/MailchimpMarketing/api/template_folders_api.rb +260 -0
  30. data/lib/MailchimpMarketing/api/templates_api.rb +331 -0
  31. data/lib/MailchimpMarketing/api/verified_domains_api.rb +242 -0
  32. data/lib/MailchimpMarketing/api_client.rb +192 -0
  33. data/lib/MailchimpMarketing/api_error.rb +38 -0
  34. data/lib/MailchimpMarketing/configuration.rb +209 -0
  35. data/lib/MailchimpMarketing/version.rb +15 -0
  36. metadata +257 -0
@@ -0,0 +1,1214 @@
1
+ =begin
2
+ #Mailchimp Marketing API
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: 3.0.1
7
+ Contact: apihelp@mailchimp.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.4.12
10
+
11
+ =end
12
+
13
+ require 'uri'
14
+
15
+ module MailchimpMarketing
16
+ class ReportsApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client)
20
+ @api_client = api_client
21
+ end
22
+ # Get campaign reports
23
+ # Get campaign reports.
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 [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)
28
+ # @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)
29
+ # @option opts [String] :type The campaign type.
30
+ # @option opts [DateTime] :before_send_time Restrict the response to campaigns sent before the set time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
31
+ # @option opts [DateTime] :since_send_time Restrict the response to campaigns sent after the set time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
32
+ # @return [CampaignReports1]
33
+ def get_all_campaign_reports(opts = {})
34
+ data, _status_code, _headers = get_all_campaign_reports_with_http_info(opts)
35
+ data
36
+ end
37
+
38
+ # Get campaign reports
39
+ # Get campaign reports.
40
+ # @param [Hash] opts the optional parameters
41
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
42
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
43
+ # @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**
44
+ # @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**.
45
+ # @option opts [String] :type The campaign type.
46
+ # @option opts [DateTime] :before_send_time Restrict the response to campaigns sent before the set time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
47
+ # @option opts [DateTime] :since_send_time Restrict the response to campaigns sent after the set time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
48
+ # @return [Array<(CampaignReports1, Fixnum, Hash)>] CampaignReports1 data, response status code and response headers
49
+ def get_all_campaign_reports_with_http_info(opts = {})
50
+ # resource path
51
+ local_var_path = '/reports'
52
+
53
+ # query parameters
54
+ query_params = {}
55
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
56
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
57
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
58
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
59
+ query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
60
+ query_params[:'before_send_time'] = opts[:'before_send_time'] if !opts[:'before_send_time'].nil?
61
+ query_params[:'since_send_time'] = opts[:'since_send_time'] if !opts[:'since_send_time'].nil?
62
+
63
+ # header parameters
64
+ header_params = {}
65
+ # HTTP header 'Accept' (if needed)
66
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
67
+ # HTTP header 'Content-Type'
68
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
69
+
70
+ # form parameters
71
+ form_params = {}
72
+
73
+ # http body (model)
74
+ post_body = nil
75
+ auth_names = ['basicAuth']
76
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
77
+ :header_params => header_params,
78
+ :query_params => query_params,
79
+ :form_params => form_params,
80
+ :body => post_body,
81
+ :auth_names => auth_names,
82
+ :return_type => 'CampaignReports1')
83
+ return data, status_code, headers
84
+ end
85
+ # Get a specific campaign report
86
+ # Get report details for a specific sent campaign.
87
+ # @param campaign_id The unique id for the campaign.
88
+ # @param [Hash] opts the optional parameters
89
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
90
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
91
+ # @return [CampaignReport]
92
+ def get_campaign_report(campaign_id = {}, opts = {})
93
+ data, _status_code, _headers = get_campaign_report_with_http_info(campaign_id, opts)
94
+ data
95
+ end
96
+
97
+ # Get a specific campaign report
98
+ # Get report details for a specific sent campaign.
99
+ # @param campaign_id The unique id for the campaign.
100
+ # @param [Hash] opts the optional parameters
101
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
102
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
103
+ # @return [Array<(CampaignReport, Fixnum, Hash)>] CampaignReport data, response status code and response headers
104
+ def get_campaign_report_with_http_info(campaign_id, opts = {})
105
+ # resource path
106
+ local_var_path = '/reports/{campaign_id}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
107
+
108
+ # query parameters
109
+ query_params = {}
110
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
111
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
112
+
113
+ # header parameters
114
+ header_params = {}
115
+ # HTTP header 'Accept' (if needed)
116
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
117
+ # HTTP header 'Content-Type'
118
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
119
+
120
+ # form parameters
121
+ form_params = {}
122
+
123
+ # http body (model)
124
+ post_body = nil
125
+ auth_names = ['basicAuth']
126
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
127
+ :header_params => header_params,
128
+ :query_params => query_params,
129
+ :form_params => form_params,
130
+ :body => post_body,
131
+ :auth_names => auth_names,
132
+ :return_type => 'CampaignReport')
133
+ return data, status_code, headers
134
+ end
135
+ # Get abuse complaints for a campaign
136
+ # Get a list of [abuse complaints](https://mailchimp.com/help/about-abuse-complaints/) for a specific campaign.
137
+ # @param campaign_id The unique id for the campaign.
138
+ # @param [Hash] opts the optional parameters
139
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
140
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
141
+ # @return [AbuseComplaints1]
142
+ def get_campaign_abuse_reports(campaign_id = {}, opts = {})
143
+ data, _status_code, _headers = get_campaign_abuse_reports_with_http_info(campaign_id, opts)
144
+ data
145
+ end
146
+
147
+ # Get abuse complaints for a campaign
148
+ # Get a list of [abuse complaints](https://mailchimp.com/help/about-abuse-complaints/) for a specific campaign.
149
+ # @param campaign_id The unique id for the campaign.
150
+ # @param [Hash] opts the optional parameters
151
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
152
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
153
+ # @return [Array<(AbuseComplaints1, Fixnum, Hash)>] AbuseComplaints1 data, response status code and response headers
154
+ def get_campaign_abuse_reports_with_http_info(campaign_id, opts = {})
155
+ # resource path
156
+ local_var_path = '/reports/{campaign_id}/abuse-reports'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
157
+
158
+ # query parameters
159
+ query_params = {}
160
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
161
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
162
+
163
+ # header parameters
164
+ header_params = {}
165
+ # HTTP header 'Accept' (if needed)
166
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
167
+ # HTTP header 'Content-Type'
168
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
169
+
170
+ # form parameters
171
+ form_params = {}
172
+
173
+ # http body (model)
174
+ post_body = nil
175
+ auth_names = ['basicAuth']
176
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
177
+ :header_params => header_params,
178
+ :query_params => query_params,
179
+ :form_params => form_params,
180
+ :body => post_body,
181
+ :auth_names => auth_names,
182
+ :return_type => 'AbuseComplaints1')
183
+ return data, status_code, headers
184
+ end
185
+ # Get information about a specific abuse report
186
+ # Get information about a specific abuse report for a campaign.
187
+ # @param campaign_id The unique id for the campaign.
188
+ # @param report_id The id for the abuse report.
189
+ # @param [Hash] opts the optional parameters
190
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
191
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
192
+ # @return [AbuseComplaint1]
193
+ def get_campaign_abuse_report(campaign_id = {}, report_id = {}, opts = {})
194
+ data, _status_code, _headers = get_campaign_abuse_report_with_http_info(campaign_id, report_id, opts)
195
+ data
196
+ end
197
+
198
+ # Get information about a specific abuse report
199
+ # Get information about a specific abuse report for a campaign.
200
+ # @param campaign_id The unique id for the campaign.
201
+ # @param report_id The id for the abuse report.
202
+ # @param [Hash] opts the optional parameters
203
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
204
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
205
+ # @return [Array<(AbuseComplaint1, Fixnum, Hash)>] AbuseComplaint1 data, response status code and response headers
206
+ def get_campaign_abuse_report_with_http_info(campaign_id, report_id, opts = {})
207
+ # resource path
208
+ local_var_path = '/reports/{campaign_id}/abuse-reports/{report_id}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'report_id' + '}', report_id.to_s)
209
+
210
+ # query parameters
211
+ query_params = {}
212
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
213
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
214
+
215
+ # header parameters
216
+ header_params = {}
217
+ # HTTP header 'Accept' (if needed)
218
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
219
+ # HTTP header 'Content-Type'
220
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
221
+
222
+ # form parameters
223
+ form_params = {}
224
+
225
+ # http body (model)
226
+ post_body = nil
227
+ auth_names = ['basicAuth']
228
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
229
+ :header_params => header_params,
230
+ :query_params => query_params,
231
+ :form_params => form_params,
232
+ :body => post_body,
233
+ :auth_names => auth_names,
234
+ :return_type => 'AbuseComplaint1')
235
+ return data, status_code, headers
236
+ end
237
+ # Get campaign feedback
238
+ # Get feedback based on a campaign's statistics. Advice feedback is based on campaign stats like opens, clicks, unsubscribes, bounces, and more.
239
+ # @param campaign_id The unique id for the campaign.
240
+ # @param [Hash] opts the optional parameters
241
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
242
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
243
+ # @return [CampaignAdviceReport]
244
+ def get_campaign_advice(campaign_id = {}, opts = {})
245
+ data, _status_code, _headers = get_campaign_advice_with_http_info(campaign_id, opts)
246
+ data
247
+ end
248
+
249
+ # Get campaign feedback
250
+ # Get feedback based on a campaign&#39;s statistics. Advice feedback is based on campaign stats like opens, clicks, unsubscribes, bounces, and more.
251
+ # @param campaign_id The unique id for the campaign.
252
+ # @param [Hash] opts the optional parameters
253
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
254
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
255
+ # @return [Array<(CampaignAdviceReport, Fixnum, Hash)>] CampaignAdviceReport data, response status code and response headers
256
+ def get_campaign_advice_with_http_info(campaign_id, opts = {})
257
+ # resource path
258
+ local_var_path = '/reports/{campaign_id}/advice'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
259
+
260
+ # query parameters
261
+ query_params = {}
262
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
263
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
264
+
265
+ # header parameters
266
+ header_params = {}
267
+ # HTTP header 'Accept' (if needed)
268
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
269
+ # HTTP header 'Content-Type'
270
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
271
+
272
+ # form parameters
273
+ form_params = {}
274
+
275
+ # http body (model)
276
+ post_body = nil
277
+ auth_names = ['basicAuth']
278
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
279
+ :header_params => header_params,
280
+ :query_params => query_params,
281
+ :form_params => form_params,
282
+ :body => post_body,
283
+ :auth_names => auth_names,
284
+ :return_type => 'CampaignAdviceReport')
285
+ return data, status_code, headers
286
+ end
287
+ # Get campaign click details
288
+ # Get information about [clicks](https://mailchimp.com/help/enable-and-view-click-tracking/) on specific links in your Mailchimp campaigns.
289
+ # @param campaign_id The unique id for the campaign.
290
+ # @param [Hash] opts the optional parameters
291
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
292
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
293
+ # @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)
294
+ # @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)
295
+ # @return [ClickDetailReport]
296
+ def get_campaign_click_details(campaign_id = {}, opts = {})
297
+ data, _status_code, _headers = get_campaign_click_details_with_http_info(campaign_id, opts)
298
+ data
299
+ end
300
+
301
+ # Get campaign click details
302
+ # Get information about [clicks](https://mailchimp.com/help/enable-and-view-click-tracking/) on specific links in your Mailchimp campaigns.
303
+ # @param campaign_id The unique id for the campaign.
304
+ # @param [Hash] opts the optional parameters
305
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
306
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
307
+ # @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**
308
+ # @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**.
309
+ # @return [Array<(ClickDetailReport, Fixnum, Hash)>] ClickDetailReport data, response status code and response headers
310
+ def get_campaign_click_details_with_http_info(campaign_id, opts = {})
311
+ # resource path
312
+ local_var_path = '/reports/{campaign_id}/click-details'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
313
+
314
+ # query parameters
315
+ query_params = {}
316
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
317
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
318
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
319
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
320
+
321
+ # header parameters
322
+ header_params = {}
323
+ # HTTP header 'Accept' (if needed)
324
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
325
+ # HTTP header 'Content-Type'
326
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
327
+
328
+ # form parameters
329
+ form_params = {}
330
+
331
+ # http body (model)
332
+ post_body = nil
333
+ auth_names = ['basicAuth']
334
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
335
+ :header_params => header_params,
336
+ :query_params => query_params,
337
+ :form_params => form_params,
338
+ :body => post_body,
339
+ :auth_names => auth_names,
340
+ :return_type => 'ClickDetailReport')
341
+ return data, status_code, headers
342
+ end
343
+ # Get click details for a specific link
344
+ # Get click details for a specific link in a campaign.
345
+ # @param campaign_id The unique id for the campaign.
346
+ # @param link_id The id for the link.
347
+ # @param [Hash] opts the optional parameters
348
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
349
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
350
+ # @return [ClickDetailReport]
351
+ def get_campaign_click_details_for_link(campaign_id = {}, link_id = {}, opts = {})
352
+ data, _status_code, _headers = get_campaign_click_details_for_link_with_http_info(campaign_id, link_id, opts)
353
+ data
354
+ end
355
+
356
+ # Get click details for a specific link
357
+ # Get click details for a specific link in a campaign.
358
+ # @param campaign_id The unique id for the campaign.
359
+ # @param link_id The id for the link.
360
+ # @param [Hash] opts the optional parameters
361
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
362
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
363
+ # @return [Array<(ClickDetailReport, Fixnum, Hash)>] ClickDetailReport data, response status code and response headers
364
+ def get_campaign_click_details_for_link_with_http_info(campaign_id, link_id, opts = {})
365
+ # resource path
366
+ local_var_path = '/reports/{campaign_id}/click-details/{link_id}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'link_id' + '}', link_id.to_s)
367
+
368
+ # query parameters
369
+ query_params = {}
370
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
371
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
372
+
373
+ # header parameters
374
+ header_params = {}
375
+ # HTTP header 'Accept' (if needed)
376
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
377
+ # HTTP header 'Content-Type'
378
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
379
+
380
+ # form parameters
381
+ form_params = {}
382
+
383
+ # http body (model)
384
+ post_body = nil
385
+ auth_names = ['basicAuth']
386
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
387
+ :header_params => header_params,
388
+ :query_params => query_params,
389
+ :form_params => form_params,
390
+ :body => post_body,
391
+ :auth_names => auth_names,
392
+ :return_type => 'ClickDetailReport')
393
+ return data, status_code, headers
394
+ end
395
+ # Get information about subscribers who clicked a link
396
+ # Get information about list members who clicked on a specific link in a campaign.
397
+ # @param campaign_id The unique id for the campaign.
398
+ # @param link_id The id for the link.
399
+ # @param [Hash] opts the optional parameters
400
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
401
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
402
+ # @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)
403
+ # @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)
404
+ # @return [ClickDetailMembers]
405
+ def get_subscribers_info(campaign_id = {}, link_id = {}, opts = {})
406
+ data, _status_code, _headers = get_subscribers_info_with_http_info(campaign_id, link_id, opts)
407
+ data
408
+ end
409
+
410
+ # Get information about subscribers who clicked a link
411
+ # Get information about list members who clicked on a specific link in a campaign.
412
+ # @param campaign_id The unique id for the campaign.
413
+ # @param link_id The id for the link.
414
+ # @param [Hash] opts the optional parameters
415
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
416
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
417
+ # @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**
418
+ # @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**.
419
+ # @return [Array<(ClickDetailMembers, Fixnum, Hash)>] ClickDetailMembers data, response status code and response headers
420
+ def get_subscribers_info_with_http_info(campaign_id, link_id, opts = {})
421
+ # resource path
422
+ local_var_path = '/reports/{campaign_id}/click-details/{link_id}/members'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'link_id' + '}', link_id.to_s)
423
+
424
+ # query parameters
425
+ query_params = {}
426
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
427
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
428
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
429
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
430
+
431
+ # header parameters
432
+ header_params = {}
433
+ # HTTP header 'Accept' (if needed)
434
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
435
+ # HTTP header 'Content-Type'
436
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
437
+
438
+ # form parameters
439
+ form_params = {}
440
+
441
+ # http body (model)
442
+ post_body = nil
443
+ auth_names = ['basicAuth']
444
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
445
+ :header_params => header_params,
446
+ :query_params => query_params,
447
+ :form_params => form_params,
448
+ :body => post_body,
449
+ :auth_names => auth_names,
450
+ :return_type => 'ClickDetailMembers')
451
+ return data, status_code, headers
452
+ end
453
+ # Get information about a specific subscriber who clicked a link
454
+ # Get information about a specific subscriber who clicked a link in a specific campaign.
455
+ # @param campaign_id The unique id for the campaign.
456
+ # @param link_id The id for the link.
457
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
458
+ # @param [Hash] opts the optional parameters
459
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
460
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
461
+ # @return [ClickDetailMember]
462
+ def get_subscriber_info(campaign_id = {}, link_id = {}, subscriber_hash = {}, opts = {})
463
+ data, _status_code, _headers = get_subscriber_info_with_http_info(campaign_id, link_id, subscriber_hash, opts)
464
+ data
465
+ end
466
+
467
+ # Get information about a specific subscriber who clicked a link
468
+ # Get information about a specific subscriber who clicked a link in a specific campaign.
469
+ # @param campaign_id The unique id for the campaign.
470
+ # @param link_id The id for the link.
471
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
472
+ # @param [Hash] opts the optional parameters
473
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
474
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
475
+ # @return [Array<(ClickDetailMember, Fixnum, Hash)>] ClickDetailMember data, response status code and response headers
476
+ def get_subscriber_info_with_http_info(campaign_id, link_id, subscriber_hash, opts = {})
477
+ # resource path
478
+ local_var_path = '/reports/{campaign_id}/click-details/{link_id}/members/{subscriber_hash}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'link_id' + '}', link_id.to_s).sub('{' + 'subscriber_hash' + '}', subscriber_hash.to_s)
479
+
480
+ # query parameters
481
+ query_params = {}
482
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
483
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
484
+
485
+ # header parameters
486
+ header_params = {}
487
+ # HTTP header 'Accept' (if needed)
488
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
489
+ # HTTP header 'Content-Type'
490
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
491
+
492
+ # form parameters
493
+ form_params = {}
494
+
495
+ # http body (model)
496
+ post_body = nil
497
+ auth_names = ['basicAuth']
498
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
499
+ :header_params => header_params,
500
+ :query_params => query_params,
501
+ :form_params => form_params,
502
+ :body => post_body,
503
+ :auth_names => auth_names,
504
+ :return_type => 'ClickDetailMember')
505
+ return data, status_code, headers
506
+ end
507
+ # Get domain performance stats
508
+ # Get statistics for the top-performing email domains in a campaign.
509
+ # @param campaign_id The unique id for the campaign.
510
+ # @param [Hash] opts the optional parameters
511
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
512
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
513
+ # @return [DomainPerformance]
514
+ def get_domain_performance_for_campaign(campaign_id = {}, opts = {})
515
+ data, _status_code, _headers = get_domain_performance_for_campaign_with_http_info(campaign_id, opts)
516
+ data
517
+ end
518
+
519
+ # Get domain performance stats
520
+ # Get statistics for the top-performing email domains in a campaign.
521
+ # @param campaign_id The unique id for the campaign.
522
+ # @param [Hash] opts the optional parameters
523
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
524
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
525
+ # @return [Array<(DomainPerformance, Fixnum, Hash)>] DomainPerformance data, response status code and response headers
526
+ def get_domain_performance_for_campaign_with_http_info(campaign_id, opts = {})
527
+ # resource path
528
+ local_var_path = '/reports/{campaign_id}/domain-performance'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
529
+
530
+ # query parameters
531
+ query_params = {}
532
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
533
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
534
+
535
+ # header parameters
536
+ header_params = {}
537
+ # HTTP header 'Accept' (if needed)
538
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
539
+ # HTTP header 'Content-Type'
540
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
541
+
542
+ # form parameters
543
+ form_params = {}
544
+
545
+ # http body (model)
546
+ post_body = nil
547
+ auth_names = ['basicAuth']
548
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
549
+ :header_params => header_params,
550
+ :query_params => query_params,
551
+ :form_params => form_params,
552
+ :body => post_body,
553
+ :auth_names => auth_names,
554
+ :return_type => 'DomainPerformance')
555
+ return data, status_code, headers
556
+ end
557
+ # __summary__
558
+ # Get breakdown of product activity for a campaign
559
+ # @param campaign_id The unique id for the campaign.
560
+ # @param [Hash] opts the optional parameters
561
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
562
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
563
+ # @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)
564
+ # @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)
565
+ # @option opts [String] :sort_field Returns files sorted by the specified field.
566
+ # @return [InlineResponse2008]
567
+ def get_ecommerce_product_activity_for_campaign(campaign_id = {}, opts = {})
568
+ data, _status_code, _headers = get_ecommerce_product_activity_for_campaign_with_http_info(campaign_id, opts)
569
+ data
570
+ end
571
+
572
+ # __summary__
573
+ # Get breakdown of product activity for a campaign
574
+ # @param campaign_id The unique id for the campaign.
575
+ # @param [Hash] opts the optional parameters
576
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
577
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
578
+ # @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**
579
+ # @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**.
580
+ # @option opts [String] :sort_field Returns files sorted by the specified field.
581
+ # @return [Array<(InlineResponse2008, Fixnum, Hash)>] InlineResponse2008 data, response status code and response headers
582
+ def get_ecommerce_product_activity_for_campaign_with_http_info(campaign_id, opts = {})
583
+ # resource path
584
+ local_var_path = '/reports/{campaign_id}/ecommerce-product-activity'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
585
+
586
+ # query parameters
587
+ query_params = {}
588
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
589
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
590
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
591
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
592
+ query_params[:'sort_field'] = opts[:'sort_field'] if !opts[:'sort_field'].nil?
593
+
594
+ # header parameters
595
+ header_params = {}
596
+ # HTTP header 'Accept' (if needed)
597
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
598
+ # HTTP header 'Content-Type'
599
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
600
+
601
+ # form parameters
602
+ form_params = {}
603
+
604
+ # http body (model)
605
+ post_body = nil
606
+ auth_names = ['basicAuth']
607
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
608
+ :header_params => header_params,
609
+ :query_params => query_params,
610
+ :form_params => form_params,
611
+ :body => post_body,
612
+ :auth_names => auth_names,
613
+ :return_type => 'InlineResponse2008')
614
+ return data, status_code, headers
615
+ end
616
+ # Get Eepurl activity
617
+ # Get a summary of social activity for the campaign, tracked by EepURL.
618
+ # @param campaign_id The unique id for the campaign.
619
+ # @param [Hash] opts the optional parameters
620
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
621
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
622
+ # @return [EepurlActivity]
623
+ def get_eepurl_activity_for_campaign(campaign_id = {}, opts = {})
624
+ data, _status_code, _headers = get_eepurl_activity_for_campaign_with_http_info(campaign_id, opts)
625
+ data
626
+ end
627
+
628
+ # Get Eepurl activity
629
+ # Get a summary of social activity for the campaign, tracked by EepURL.
630
+ # @param campaign_id The unique id for the campaign.
631
+ # @param [Hash] opts the optional parameters
632
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
633
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
634
+ # @return [Array<(EepurlActivity, Fixnum, Hash)>] EepurlActivity data, response status code and response headers
635
+ def get_eepurl_activity_for_campaign_with_http_info(campaign_id, opts = {})
636
+ # resource path
637
+ local_var_path = '/reports/{campaign_id}/eepurl'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
638
+
639
+ # query parameters
640
+ query_params = {}
641
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
642
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
643
+
644
+ # header parameters
645
+ header_params = {}
646
+ # HTTP header 'Accept' (if needed)
647
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
648
+ # HTTP header 'Content-Type'
649
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
650
+
651
+ # form parameters
652
+ form_params = {}
653
+
654
+ # http body (model)
655
+ post_body = nil
656
+ auth_names = ['basicAuth']
657
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
658
+ :header_params => header_params,
659
+ :query_params => query_params,
660
+ :form_params => form_params,
661
+ :body => post_body,
662
+ :auth_names => auth_names,
663
+ :return_type => 'EepurlActivity')
664
+ return data, status_code, headers
665
+ end
666
+ # Get email activity
667
+ # Get a list of member's subscriber activity in a specific campaign.
668
+ # @param campaign_id The unique id for the campaign.
669
+ # @param [Hash] opts the optional parameters
670
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
671
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
672
+ # @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)
673
+ # @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)
674
+ # @option opts [String] :since Restrict results to email activity events that occur after a specific time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
675
+ # @return [EmailActivity]
676
+ def get_email_activity_for_campaign(campaign_id = {}, opts = {})
677
+ data, _status_code, _headers = get_email_activity_for_campaign_with_http_info(campaign_id, opts)
678
+ data
679
+ end
680
+
681
+ # Get email activity
682
+ # Get a list of member&#39;s subscriber activity in a specific campaign.
683
+ # @param campaign_id The unique id for the campaign.
684
+ # @param [Hash] opts the optional parameters
685
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
686
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
687
+ # @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**
688
+ # @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**.
689
+ # @option opts [String] :since Restrict results to email activity events that occur after a specific time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
690
+ # @return [Array<(EmailActivity, Fixnum, Hash)>] EmailActivity data, response status code and response headers
691
+ def get_email_activity_for_campaign_with_http_info(campaign_id, opts = {})
692
+ # resource path
693
+ local_var_path = '/reports/{campaign_id}/email-activity'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
694
+
695
+ # query parameters
696
+ query_params = {}
697
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
698
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
699
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
700
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
701
+ query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
702
+
703
+ # header parameters
704
+ header_params = {}
705
+ # HTTP header 'Accept' (if needed)
706
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
707
+ # HTTP header 'Content-Type'
708
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
709
+
710
+ # form parameters
711
+ form_params = {}
712
+
713
+ # http body (model)
714
+ post_body = nil
715
+ auth_names = ['basicAuth']
716
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
717
+ :header_params => header_params,
718
+ :query_params => query_params,
719
+ :form_params => form_params,
720
+ :body => post_body,
721
+ :auth_names => auth_names,
722
+ :return_type => 'EmailActivity')
723
+ return data, status_code, headers
724
+ end
725
+ # Get email activity for a specific subscriber
726
+ # Get a specific list member's activity in a campaign including opens, clicks, and bounces.
727
+ # @param campaign_id The unique id for the campaign.
728
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
729
+ # @param [Hash] opts the optional parameters
730
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
731
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
732
+ # @option opts [String] :since Restrict results to email activity events that occur after a specific time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
733
+ # @return [EmailActivity]
734
+ def get_email_activity_for_subscriber(campaign_id = {}, subscriber_hash = {}, opts = {})
735
+ data, _status_code, _headers = get_email_activity_for_subscriber_with_http_info(campaign_id, subscriber_hash, opts)
736
+ data
737
+ end
738
+
739
+ # Get email activity for a specific subscriber
740
+ # Get a specific list member&#39;s activity in a campaign including opens, clicks, and bounces.
741
+ # @param campaign_id The unique id for the campaign.
742
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
743
+ # @param [Hash] opts the optional parameters
744
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
745
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
746
+ # @option opts [String] :since Restrict results to email activity events that occur after a specific time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
747
+ # @return [Array<(EmailActivity, Fixnum, Hash)>] EmailActivity data, response status code and response headers
748
+ def get_email_activity_for_subscriber_with_http_info(campaign_id, subscriber_hash, opts = {})
749
+ # resource path
750
+ local_var_path = '/reports/{campaign_id}/email-activity/{subscriber_hash}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'subscriber_hash' + '}', subscriber_hash.to_s)
751
+
752
+ # query parameters
753
+ query_params = {}
754
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
755
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
756
+ query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
757
+
758
+ # header parameters
759
+ header_params = {}
760
+ # HTTP header 'Accept' (if needed)
761
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
762
+ # HTTP header 'Content-Type'
763
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
764
+
765
+ # form parameters
766
+ form_params = {}
767
+
768
+ # http body (model)
769
+ post_body = nil
770
+ auth_names = ['basicAuth']
771
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
772
+ :header_params => header_params,
773
+ :query_params => query_params,
774
+ :form_params => form_params,
775
+ :body => post_body,
776
+ :auth_names => auth_names,
777
+ :return_type => 'EmailActivity')
778
+ return data, status_code, headers
779
+ end
780
+ # Get top open locations
781
+ # Get top open locations for a specific campaign.
782
+ # @param campaign_id The unique id for the campaign.
783
+ # @param [Hash] opts the optional parameters
784
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
785
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
786
+ # @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)
787
+ # @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)
788
+ # @return [OpenLocations]
789
+ def get_locations_for_campaign(campaign_id = {}, opts = {})
790
+ data, _status_code, _headers = get_locations_for_campaign_with_http_info(campaign_id, opts)
791
+ data
792
+ end
793
+
794
+ # Get top open locations
795
+ # Get top open locations for a specific campaign.
796
+ # @param campaign_id The unique id for the campaign.
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
+ # @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**
801
+ # @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**.
802
+ # @return [Array<(OpenLocations, Fixnum, Hash)>] OpenLocations data, response status code and response headers
803
+ def get_locations_for_campaign_with_http_info(campaign_id, opts = {})
804
+ # resource path
805
+ local_var_path = '/reports/{campaign_id}/locations'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
806
+
807
+ # query parameters
808
+ query_params = {}
809
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
810
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
811
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
812
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
813
+
814
+ # header parameters
815
+ header_params = {}
816
+ # HTTP header 'Accept' (if needed)
817
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
818
+ # HTTP header 'Content-Type'
819
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
820
+
821
+ # form parameters
822
+ form_params = {}
823
+
824
+ # http body (model)
825
+ post_body = nil
826
+ auth_names = ['basicAuth']
827
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
828
+ :header_params => header_params,
829
+ :query_params => query_params,
830
+ :form_params => form_params,
831
+ :body => post_body,
832
+ :auth_names => auth_names,
833
+ :return_type => 'OpenLocations')
834
+ return data, status_code, headers
835
+ end
836
+ # Get campaign Open details
837
+ # Get detailed information about any campaign emails that were opened by a list member.
838
+ # @param campaign_id The unique id for the campaign.
839
+ # @param [Hash] opts the optional parameters
840
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
841
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
842
+ # @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)
843
+ # @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)
844
+ # @option opts [String] :since Restrict results to campaign open events that occur after a specific time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
845
+ # @return [OpenDetailReport]
846
+ def get_campaign_open_details(campaign_id = {}, opts = {})
847
+ data, _status_code, _headers = get_campaign_open_details_with_http_info(campaign_id, opts)
848
+ data
849
+ end
850
+
851
+ # Get campaign Open details
852
+ # Get detailed information about any campaign emails that were opened by a list member.
853
+ # @param campaign_id The unique id for the campaign.
854
+ # @param [Hash] opts the optional parameters
855
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
856
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
857
+ # @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**
858
+ # @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**.
859
+ # @option opts [String] :since Restrict results to campaign open events that occur after a specific time. We recommend [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) time format: 2015-10-21T15:41:36+00:00.
860
+ # @return [Array<(OpenDetailReport, Fixnum, Hash)>] OpenDetailReport data, response status code and response headers
861
+ def get_campaign_open_details_with_http_info(campaign_id, opts = {})
862
+ # resource path
863
+ local_var_path = '/reports/{campaign_id}/open-details'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
864
+
865
+ # query parameters
866
+ query_params = {}
867
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
868
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
869
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
870
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
871
+ query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
872
+
873
+ # header parameters
874
+ header_params = {}
875
+ # HTTP header 'Accept' (if needed)
876
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
877
+ # HTTP header 'Content-Type'
878
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
879
+
880
+ # form parameters
881
+ form_params = {}
882
+
883
+ # http body (model)
884
+ post_body = nil
885
+ auth_names = ['basicAuth']
886
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
887
+ :header_params => header_params,
888
+ :query_params => query_params,
889
+ :form_params => form_params,
890
+ :body => post_body,
891
+ :auth_names => auth_names,
892
+ :return_type => 'OpenDetailReport')
893
+ return data, status_code, headers
894
+ end
895
+ # Get information about a specific subscriber who opened a campaign
896
+ # Get information about a specific subscriber who opened a campaign.
897
+ # @param campaign_id The unique id for the campaign.
898
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
899
+ # @param [Hash] opts the optional parameters
900
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
901
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
902
+ # @return [OpenActivity]
903
+ def get_subscriber_info_for_opened_campaign(campaign_id = {}, subscriber_hash = {}, opts = {})
904
+ data, _status_code, _headers = get_subscriber_info_for_opened_campaign_with_http_info(campaign_id, subscriber_hash, opts)
905
+ data
906
+ end
907
+
908
+ # Get information about a specific subscriber who opened a campaign
909
+ # Get information about a specific subscriber who opened a campaign.
910
+ # @param campaign_id The unique id for the campaign.
911
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
912
+ # @param [Hash] opts the optional parameters
913
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
914
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
915
+ # @return [Array<(OpenActivity, Fixnum, Hash)>] OpenActivity data, response status code and response headers
916
+ def get_subscriber_info_for_opened_campaign_with_http_info(campaign_id, subscriber_hash, opts = {})
917
+ # resource path
918
+ local_var_path = '/reports/{campaign_id}/open-details/{subscriber_hash}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'subscriber_hash' + '}', subscriber_hash.to_s)
919
+
920
+ # query parameters
921
+ query_params = {}
922
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
923
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
924
+
925
+ # header parameters
926
+ header_params = {}
927
+ # HTTP header 'Accept' (if needed)
928
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
929
+ # HTTP header 'Content-Type'
930
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
931
+
932
+ # form parameters
933
+ form_params = {}
934
+
935
+ # http body (model)
936
+ post_body = nil
937
+ auth_names = ['basicAuth']
938
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
939
+ :header_params => header_params,
940
+ :query_params => query_params,
941
+ :form_params => form_params,
942
+ :body => post_body,
943
+ :auth_names => auth_names,
944
+ :return_type => 'OpenActivity')
945
+ return data, status_code, headers
946
+ end
947
+ # Get information about campaign recipients
948
+ # Get information about campaign recipients.
949
+ # @param campaign_id The unique id for the campaign.
950
+ # @param [Hash] opts the optional parameters
951
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
952
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
953
+ # @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)
954
+ # @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)
955
+ # @return [SentTo]
956
+ def get_campaign_recipients(campaign_id = {}, opts = {})
957
+ data, _status_code, _headers = get_campaign_recipients_with_http_info(campaign_id, opts)
958
+ data
959
+ end
960
+
961
+ # Get information about campaign recipients
962
+ # Get information about campaign recipients.
963
+ # @param campaign_id The unique id for the campaign.
964
+ # @param [Hash] opts the optional parameters
965
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
966
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
967
+ # @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**
968
+ # @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**.
969
+ # @return [Array<(SentTo, Fixnum, Hash)>] SentTo data, response status code and response headers
970
+ def get_campaign_recipients_with_http_info(campaign_id, opts = {})
971
+ # resource path
972
+ local_var_path = '/reports/{campaign_id}/sent-to'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
973
+
974
+ # query parameters
975
+ query_params = {}
976
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
977
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
978
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
979
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
980
+
981
+ # header parameters
982
+ header_params = {}
983
+ # HTTP header 'Accept' (if needed)
984
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
985
+ # HTTP header 'Content-Type'
986
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
987
+
988
+ # form parameters
989
+ form_params = {}
990
+
991
+ # http body (model)
992
+ post_body = nil
993
+ auth_names = ['basicAuth']
994
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
995
+ :header_params => header_params,
996
+ :query_params => query_params,
997
+ :form_params => form_params,
998
+ :body => post_body,
999
+ :auth_names => auth_names,
1000
+ :return_type => 'SentTo')
1001
+ return data, status_code, headers
1002
+ end
1003
+ # Get information about a specific campaign recipient
1004
+ # Get information about a specific campaign recipient.
1005
+ # @param campaign_id The unique id for the campaign.
1006
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
1007
+ # @param [Hash] opts the optional parameters
1008
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1009
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1010
+ # @return [SentTo]
1011
+ def get_campaign_recipient(campaign_id = {}, subscriber_hash = {}, opts = {})
1012
+ data, _status_code, _headers = get_campaign_recipient_with_http_info(campaign_id, subscriber_hash, opts)
1013
+ data
1014
+ end
1015
+
1016
+ # Get information about a specific campaign recipient
1017
+ # Get information about a specific campaign recipient.
1018
+ # @param campaign_id The unique id for the campaign.
1019
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
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 [Array<(SentTo, Fixnum, Hash)>] SentTo data, response status code and response headers
1024
+ def get_campaign_recipient_with_http_info(campaign_id, subscriber_hash, opts = {})
1025
+ # resource path
1026
+ local_var_path = '/reports/{campaign_id}/sent-to/{subscriber_hash}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'subscriber_hash' + '}', subscriber_hash.to_s)
1027
+
1028
+ # query parameters
1029
+ query_params = {}
1030
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1031
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1032
+
1033
+ # header parameters
1034
+ header_params = {}
1035
+ # HTTP header 'Accept' (if needed)
1036
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1037
+ # HTTP header 'Content-Type'
1038
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1039
+
1040
+ # form parameters
1041
+ form_params = {}
1042
+
1043
+ # http body (model)
1044
+ post_body = nil
1045
+ auth_names = ['basicAuth']
1046
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1047
+ :header_params => header_params,
1048
+ :query_params => query_params,
1049
+ :form_params => form_params,
1050
+ :body => post_body,
1051
+ :auth_names => auth_names,
1052
+ :return_type => 'SentTo')
1053
+ return data, status_code, headers
1054
+ end
1055
+ # Get reports for child campaigns
1056
+ # Get a list of reports with child campaigns for a specific parent campaign.
1057
+ # @param campaign_id The unique id for the campaign.
1058
+ # @param [Hash] opts the optional parameters
1059
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1060
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1061
+ # @return [CampaignSubReports]
1062
+ def get_sub_reports_for_campaign(campaign_id = {}, opts = {})
1063
+ data, _status_code, _headers = get_sub_reports_for_campaign_with_http_info(campaign_id, opts)
1064
+ data
1065
+ end
1066
+
1067
+ # Get reports for child campaigns
1068
+ # Get a list of reports with child campaigns for a specific parent campaign.
1069
+ # @param campaign_id The unique id for the campaign.
1070
+ # @param [Hash] opts the optional parameters
1071
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1072
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1073
+ # @return [Array<(CampaignSubReports, Fixnum, Hash)>] CampaignSubReports data, response status code and response headers
1074
+ def get_sub_reports_for_campaign_with_http_info(campaign_id, opts = {})
1075
+ # resource path
1076
+ local_var_path = '/reports/{campaign_id}/sub-reports'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
1077
+
1078
+ # query parameters
1079
+ query_params = {}
1080
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1081
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1082
+
1083
+ # header parameters
1084
+ header_params = {}
1085
+ # HTTP header 'Accept' (if needed)
1086
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1087
+ # HTTP header 'Content-Type'
1088
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1089
+
1090
+ # form parameters
1091
+ form_params = {}
1092
+
1093
+ # http body (model)
1094
+ post_body = nil
1095
+ auth_names = ['basicAuth']
1096
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1097
+ :header_params => header_params,
1098
+ :query_params => query_params,
1099
+ :form_params => form_params,
1100
+ :body => post_body,
1101
+ :auth_names => auth_names,
1102
+ :return_type => 'CampaignSubReports')
1103
+ return data, status_code, headers
1104
+ end
1105
+ # Get unsubscribed list members
1106
+ # Get information about members who have unsubscribed from a specific campaign.
1107
+ # @param campaign_id The unique id for the campaign.
1108
+ # @param [Hash] opts the optional parameters
1109
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1110
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1111
+ # @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)
1112
+ # @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)
1113
+ # @return [Unsubscribes]
1114
+ def get_unsubscribed_list_for_campaign(campaign_id = {}, opts = {})
1115
+ data, _status_code, _headers = get_unsubscribed_list_for_campaign_with_http_info(campaign_id, opts)
1116
+ data
1117
+ end
1118
+
1119
+ # Get unsubscribed list members
1120
+ # Get information about members who have unsubscribed from a specific campaign.
1121
+ # @param campaign_id The unique id for the campaign.
1122
+ # @param [Hash] opts the optional parameters
1123
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1124
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1125
+ # @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**
1126
+ # @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**.
1127
+ # @return [Array<(Unsubscribes, Fixnum, Hash)>] Unsubscribes data, response status code and response headers
1128
+ def get_unsubscribed_list_for_campaign_with_http_info(campaign_id, opts = {})
1129
+ # resource path
1130
+ local_var_path = '/reports/{campaign_id}/unsubscribed'.sub('{' + 'campaign_id' + '}', campaign_id.to_s)
1131
+
1132
+ # query parameters
1133
+ query_params = {}
1134
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1135
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1136
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
1137
+ query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
1138
+
1139
+ # header parameters
1140
+ header_params = {}
1141
+ # HTTP header 'Accept' (if needed)
1142
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1143
+ # HTTP header 'Content-Type'
1144
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1145
+
1146
+ # form parameters
1147
+ form_params = {}
1148
+
1149
+ # http body (model)
1150
+ post_body = nil
1151
+ auth_names = ['basicAuth']
1152
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1153
+ :header_params => header_params,
1154
+ :query_params => query_params,
1155
+ :form_params => form_params,
1156
+ :body => post_body,
1157
+ :auth_names => auth_names,
1158
+ :return_type => 'Unsubscribes')
1159
+ return data, status_code, headers
1160
+ end
1161
+ # Get information about a specific list member who unsubscribed
1162
+ # Get information about a specific list member who unsubscribed from a campaign.
1163
+ # @param campaign_id The unique id for the campaign.
1164
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
1165
+ # @param [Hash] opts the optional parameters
1166
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1167
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1168
+ # @return [Unsubscribes]
1169
+ def get_unsubscribed_list_member(campaign_id = {}, subscriber_hash = {}, opts = {})
1170
+ data, _status_code, _headers = get_unsubscribed_list_member_with_http_info(campaign_id, subscriber_hash, opts)
1171
+ data
1172
+ end
1173
+
1174
+ # Get information about a specific list member who unsubscribed
1175
+ # Get information about a specific list member who unsubscribed from a campaign.
1176
+ # @param campaign_id The unique id for the campaign.
1177
+ # @param subscriber_hash The MD5 hash of the lowercase version of the list member&#39;s email address.
1178
+ # @param [Hash] opts the optional parameters
1179
+ # @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
1180
+ # @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
1181
+ # @return [Array<(Unsubscribes, Fixnum, Hash)>] Unsubscribes data, response status code and response headers
1182
+ def get_unsubscribed_list_member_with_http_info(campaign_id, subscriber_hash, opts = {})
1183
+ # resource path
1184
+ local_var_path = '/reports/{campaign_id}/unsubscribed/{subscriber_hash}'.sub('{' + 'campaign_id' + '}', campaign_id.to_s).sub('{' + 'subscriber_hash' + '}', subscriber_hash.to_s)
1185
+
1186
+ # query parameters
1187
+ query_params = {}
1188
+ query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
1189
+ query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
1190
+
1191
+ # header parameters
1192
+ header_params = {}
1193
+ # HTTP header 'Accept' (if needed)
1194
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
1195
+ # HTTP header 'Content-Type'
1196
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1197
+
1198
+ # form parameters
1199
+ form_params = {}
1200
+
1201
+ # http body (model)
1202
+ post_body = nil
1203
+ auth_names = ['basicAuth']
1204
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1205
+ :header_params => header_params,
1206
+ :query_params => query_params,
1207
+ :form_params => form_params,
1208
+ :body => post_body,
1209
+ :auth_names => auth_names,
1210
+ :return_type => 'Unsubscribes')
1211
+ return data, status_code, headers
1212
+ end
1213
+ end
1214
+ end