MailchimpMarketing 3.0.5 → 3.0.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/MailchimpMarketing.gemspec +2 -2
- data/README.md +22 -26
- data/lib/MailchimpMarketing.rb +1 -1
- data/lib/MailchimpMarketing/api/activity_feed_api.rb +10 -71
- data/lib/MailchimpMarketing/api/authorized_apps_api.rb +16 -116
- data/lib/MailchimpMarketing/api/automations_api.rb +110 -704
- data/lib/MailchimpMarketing/api/batch_webhooks_api.rb +27 -187
- data/lib/MailchimpMarketing/api/batches_api.rb +21 -150
- data/lib/MailchimpMarketing/api/campaign_folders_api.rb +27 -187
- data/lib/MailchimpMarketing/api/campaigns_api.rb +124 -828
- data/lib/MailchimpMarketing/api/connected_sites_api.rb +26 -184
- data/lib/MailchimpMarketing/api/conversations_api.rb +30 -210
- data/lib/MailchimpMarketing/api/dashboard_api.rb +25 -227
- data/lib/MailchimpMarketing/api/ecommerce_api.rb +387 -2371
- data/lib/MailchimpMarketing/api/external_auths_api.rb +16 -116
- data/lib/MailchimpMarketing/api/facebook_ads_api.rb +13 -85
- data/lib/MailchimpMarketing/api/file_manager_api.rb +59 -424
- data/lib/MailchimpMarketing/api/landing_pages_api.rb +44 -296
- data/lib/MailchimpMarketing/api/lists_api.rb +420 -2707
- data/lib/MailchimpMarketing/api/ping_api.rb +5 -34
- data/lib/MailchimpMarketing/api/postcards_api.rb +7 -42
- data/lib/MailchimpMarketing/api/reporting_api.rb +34 -243
- data/lib/MailchimpMarketing/api/reports_api.rb +130 -925
- data/lib/MailchimpMarketing/api/root_api.rb +5 -38
- data/lib/MailchimpMarketing/api/search_campaigns_api.rb +6 -40
- data/lib/MailchimpMarketing/api/search_members_api.rb +6 -42
- data/lib/MailchimpMarketing/api/template_folders_api.rb +27 -187
- data/lib/MailchimpMarketing/api/templates_api.rb +33 -240
- data/lib/MailchimpMarketing/api/verified_domains_api.rb +26 -175
- data/lib/MailchimpMarketing/api_client.rb +15 -161
- data/lib/MailchimpMarketing/api_error.rb +1 -1
- data/lib/MailchimpMarketing/configuration.rb +1 -1
- data/lib/MailchimpMarketing/version.rb +2 -2
- metadata +5 -11
@@ -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.
|
6
|
+
OpenAPI spec version: 3.0.10
|
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
|
@@ -19,46 +19,17 @@ module MailchimpMarketing
|
|
19
19
|
def initialize(api_client)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
# Ping
|
23
|
-
# A health check for the API that won't return any account-specific information.
|
24
|
-
# @param [Hash] opts the optional parameters
|
25
|
-
# @return [APIHealthStatus]
|
26
|
-
def get(opts = {})
|
27
|
-
data, _status_code, _headers = get_with_http_info(opts)
|
28
|
-
data
|
29
|
-
end
|
30
22
|
|
31
23
|
# Ping
|
32
|
-
|
33
|
-
# @param [Hash] opts the optional parameters
|
34
|
-
# @return [Array<(APIHealthStatus, Fixnum, Hash)>] APIHealthStatus data, response status code and response headers
|
35
|
-
def get_with_http_info(opts = {})
|
36
|
-
# resource path
|
37
|
-
local_var_path = '/ping'
|
24
|
+
def get(opts = {})
|
38
25
|
|
39
|
-
# query parameters
|
40
26
|
query_params = {}
|
41
|
-
|
42
|
-
# header parameters
|
43
|
-
header_params = {}
|
44
|
-
# HTTP header 'Accept' (if needed)
|
45
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
46
|
-
# HTTP header 'Content-Type'
|
47
|
-
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
48
|
-
|
49
|
-
# form parameters
|
50
|
-
form_params = {}
|
51
|
-
|
52
|
-
# http body (model)
|
53
27
|
post_body = nil
|
54
|
-
|
28
|
+
|
29
|
+
local_var_path = '/ping'
|
55
30
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
56
|
-
:header_params => header_params,
|
57
31
|
:query_params => query_params,
|
58
|
-
:
|
59
|
-
:body => post_body,
|
60
|
-
:auth_names => auth_names,
|
61
|
-
:return_type => 'APIHealthStatus')
|
32
|
+
:body => post_body)
|
62
33
|
return data, status_code, headers
|
63
34
|
end
|
64
35
|
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.
|
6
|
+
OpenAPI spec version: 3.0.10
|
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
|
@@ -19,58 +19,23 @@ module MailchimpMarketing
|
|
19
19
|
def initialize(api_client)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
# List postcards
|
23
|
-
# Get all of a user's postcards.
|
24
|
-
# @param [Hash] opts the optional parameters
|
25
|
-
# @option opts [String] :sort_dir Determines the order direction for sorted results.
|
26
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
27
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
28
|
-
# @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)
|
29
|
-
# @return [InlineResponse2007]
|
30
|
-
def get_all(opts = {})
|
31
|
-
data, _status_code, _headers = get_all_with_http_info(opts)
|
32
|
-
data
|
33
|
-
end
|
34
22
|
|
35
23
|
# List postcards
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
40
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
41
|
-
# @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**
|
42
|
-
# @return [Array<(InlineResponse2007, Fixnum, Hash)>] InlineResponse2007 data, response status code and response headers
|
43
|
-
def get_all_with_http_info(opts = {})
|
44
|
-
# resource path
|
45
|
-
local_var_path = '/postcards'
|
24
|
+
def get_all(opts = {})
|
25
|
+
fail ArgumentError, 'invalid value for "sort_dir", must be one of ASC, DESC' if opts[:'sort_dir'] && !['ASC', 'DESC'].include?(opts[:'sort_dir'])
|
26
|
+
fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
|
46
27
|
|
47
|
-
# query parameters
|
48
28
|
query_params = {}
|
49
29
|
query_params[:'sort_dir'] = opts[:'sort_dir'] if !opts[:'sort_dir'].nil?
|
50
30
|
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
|
51
31
|
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
|
52
32
|
query_params[:'count'] = opts[:'count'] if !opts[:'count'].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
|
-
form_params = {}
|
63
|
-
|
64
|
-
# http body (model)
|
65
33
|
post_body = nil
|
66
|
-
|
34
|
+
|
35
|
+
local_var_path = '/postcards'
|
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
|
-
:
|
71
|
-
:body => post_body,
|
72
|
-
:auth_names => auth_names,
|
73
|
-
:return_type => 'InlineResponse2007')
|
38
|
+
:body => post_body)
|
74
39
|
return data, status_code, headers
|
75
40
|
end
|
76
41
|
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.
|
6
|
+
OpenAPI spec version: 3.0.10
|
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
|
@@ -19,78 +19,26 @@ module MailchimpMarketing
|
|
19
19
|
def initialize(api_client)
|
20
20
|
@api_client = api_client
|
21
21
|
end
|
22
|
-
# List reporting resources
|
23
|
-
# Get information about the reporting endpoint's resources.
|
24
|
-
# @param [Hash] opts the optional parameters
|
25
|
-
# @return [Reporting]
|
26
|
-
def info(opts = {})
|
27
|
-
data, _status_code, _headers = info_with_http_info(opts)
|
28
|
-
data
|
29
|
-
end
|
30
22
|
|
31
23
|
# List reporting resources
|
32
|
-
|
33
|
-
# @param [Hash] opts the optional parameters
|
34
|
-
# @return [Array<(Reporting, Fixnum, Hash)>] Reporting data, response status code and response headers
|
35
|
-
def info_with_http_info(opts = {})
|
36
|
-
# resource path
|
37
|
-
local_var_path = '/reporting'
|
24
|
+
def info(opts = {})
|
38
25
|
|
39
|
-
# query parameters
|
40
26
|
query_params = {}
|
41
|
-
|
42
|
-
# header parameters
|
43
|
-
header_params = {}
|
44
|
-
# HTTP header 'Accept' (if needed)
|
45
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
46
|
-
# HTTP header 'Content-Type'
|
47
|
-
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
48
|
-
|
49
|
-
# form parameters
|
50
|
-
form_params = {}
|
51
|
-
|
52
|
-
# http body (model)
|
53
27
|
post_body = nil
|
54
|
-
|
28
|
+
|
29
|
+
local_var_path = '/reporting'
|
55
30
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
56
|
-
:header_params => header_params,
|
57
31
|
:query_params => query_params,
|
58
|
-
:
|
59
|
-
:body => post_body,
|
60
|
-
:auth_names => auth_names,
|
61
|
-
:return_type => 'Reporting')
|
32
|
+
:body => post_body)
|
62
33
|
return data, status_code, headers
|
63
34
|
end
|
64
|
-
# List facebook ads reports
|
65
|
-
# Get reports of Facebook ads.
|
66
|
-
# @param [Hash] opts the optional parameters
|
67
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
68
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
69
|
-
# @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)
|
70
|
-
# @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)
|
71
|
-
# @option opts [String] :sort_field Returns files sorted by the specified field.
|
72
|
-
# @option opts [String] :sort_dir Determines the order direction for sorted results.
|
73
|
-
# @return [InlineResponse20011]
|
74
|
-
def get_facebook_ads_report_all(opts = {})
|
75
|
-
data, _status_code, _headers = get_facebook_ads_report_all_with_http_info(opts)
|
76
|
-
data
|
77
|
-
end
|
78
35
|
|
79
36
|
# List facebook ads reports
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
# @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**
|
85
|
-
# @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**.
|
86
|
-
# @option opts [String] :sort_field Returns files sorted by the specified field.
|
87
|
-
# @option opts [String] :sort_dir Determines the order direction for sorted results.
|
88
|
-
# @return [Array<(InlineResponse20011, Fixnum, Hash)>] InlineResponse20011 data, response status code and response headers
|
89
|
-
def get_facebook_ads_report_all_with_http_info(opts = {})
|
90
|
-
# resource path
|
91
|
-
local_var_path = '/reporting/facebook-ads'
|
37
|
+
def get_facebook_ads_report_all(opts = {})
|
38
|
+
fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
|
39
|
+
fail ArgumentError, 'invalid value for "sort_field", must be one of created_at, updated_at, end_time' if opts[:'sort_field'] && !['created_at', 'updated_at', 'end_time'].include?(opts[:'sort_field'])
|
40
|
+
fail ArgumentError, 'invalid value for "sort_dir", must be one of ASC, DESC' if opts[:'sort_dir'] && !['ASC', 'DESC'].include?(opts[:'sort_dir'])
|
92
41
|
|
93
|
-
# query parameters
|
94
42
|
query_params = {}
|
95
43
|
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
|
96
44
|
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
|
@@ -98,240 +46,83 @@ module MailchimpMarketing
|
|
98
46
|
query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
|
99
47
|
query_params[:'sort_field'] = opts[:'sort_field'] if !opts[:'sort_field'].nil?
|
100
48
|
query_params[:'sort_dir'] = opts[:'sort_dir'] if !opts[:'sort_dir'].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
|
-
form_params = {}
|
111
|
-
|
112
|
-
# http body (model)
|
113
49
|
post_body = nil
|
114
|
-
|
50
|
+
|
51
|
+
local_var_path = '/reporting/facebook-ads'
|
115
52
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
116
|
-
:header_params => header_params,
|
117
53
|
:query_params => query_params,
|
118
|
-
:
|
119
|
-
:body => post_body,
|
120
|
-
:auth_names => auth_names,
|
121
|
-
:return_type => 'InlineResponse20011')
|
54
|
+
:body => post_body)
|
122
55
|
return data, status_code, headers
|
123
56
|
end
|
124
|
-
# Get facebook ad report
|
125
|
-
# Get report of a Facebook ad.
|
126
|
-
# @param outreach_id The outreach id.
|
127
|
-
# @param [Hash] opts the optional parameters
|
128
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
129
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
130
|
-
# @return [InlineResponse20012]
|
131
|
-
def get_facebook_ad_report(outreach_id = {}, opts = {})
|
132
|
-
data, _status_code, _headers = get_facebook_ad_report_with_http_info(outreach_id, opts)
|
133
|
-
data
|
134
|
-
end
|
135
57
|
|
136
58
|
# Get facebook ad report
|
137
|
-
|
138
|
-
|
139
|
-
# @param [Hash] opts the optional parameters
|
140
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
141
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
142
|
-
# @return [Array<(InlineResponse20012, Fixnum, Hash)>] InlineResponse20012 data, response status code and response headers
|
143
|
-
def get_facebook_ad_report_with_http_info(outreach_id, opts = {})
|
144
|
-
# resource path
|
145
|
-
local_var_path = '/reporting/facebook-ads/{outreach_id}'.sub('{' + 'outreach_id' + '}', outreach_id.to_s)
|
59
|
+
def get_facebook_ad_report(outreach_id, opts = {})
|
60
|
+
fail ArgumentError, "Missing required param: 'outreach_id'" if outreach_id.nil?
|
146
61
|
|
147
|
-
# query parameters
|
148
62
|
query_params = {}
|
149
63
|
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
|
150
64
|
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
|
151
|
-
|
152
|
-
# header parameters
|
153
|
-
header_params = {}
|
154
|
-
# HTTP header 'Accept' (if needed)
|
155
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
156
|
-
# HTTP header 'Content-Type'
|
157
|
-
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
158
|
-
|
159
|
-
# form parameters
|
160
|
-
form_params = {}
|
161
|
-
|
162
|
-
# http body (model)
|
163
65
|
post_body = nil
|
164
|
-
|
66
|
+
|
67
|
+
local_var_path = '/reporting/facebook-ads/{outreach_id}'.sub('{' + 'outreach_id' + '}', outreach_id.to_s)
|
165
68
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
166
|
-
:header_params => header_params,
|
167
69
|
:query_params => query_params,
|
168
|
-
:
|
169
|
-
:body => post_body,
|
170
|
-
:auth_names => auth_names,
|
171
|
-
:return_type => 'InlineResponse20012')
|
70
|
+
:body => post_body)
|
172
71
|
return data, status_code, headers
|
173
72
|
end
|
174
|
-
# List facebook ecommerce report
|
175
|
-
# Get breakdown of product activity for an outreach.
|
176
|
-
# @param outreach_id The outreach id.
|
177
|
-
# @param [Hash] opts the optional parameters
|
178
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
179
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
180
|
-
# @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)
|
181
|
-
# @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)
|
182
|
-
# @option opts [String] :sort_field Returns files sorted by the specified field.
|
183
|
-
# @return [InlineResponse2008]
|
184
|
-
def get_facebook_ad_product_activity_report(outreach_id = {}, opts = {})
|
185
|
-
data, _status_code, _headers = get_facebook_ad_product_activity_report_with_http_info(outreach_id, opts)
|
186
|
-
data
|
187
|
-
end
|
188
73
|
|
189
74
|
# List facebook ecommerce report
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
195
|
-
# @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**
|
196
|
-
# @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**.
|
197
|
-
# @option opts [String] :sort_field Returns files sorted by the specified field.
|
198
|
-
# @return [Array<(InlineResponse2008, Fixnum, Hash)>] InlineResponse2008 data, response status code and response headers
|
199
|
-
def get_facebook_ad_product_activity_report_with_http_info(outreach_id, opts = {})
|
200
|
-
# resource path
|
201
|
-
local_var_path = '/reporting/facebook-ads/{outreach_id}/ecommerce-product-activity'.sub('{' + 'outreach_id' + '}', outreach_id.to_s)
|
75
|
+
def get_facebook_ad_product_activity_report(outreach_id, opts = {})
|
76
|
+
fail ArgumentError, "Missing required param: 'outreach_id'" if outreach_id.nil?
|
77
|
+
fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
|
78
|
+
fail ArgumentError, 'invalid value for "sort_field", must be one of title, total_revenue, total_purchased' if opts[:'sort_field'] && !['title', 'total_revenue', 'total_purchased'].include?(opts[:'sort_field'])
|
202
79
|
|
203
|
-
# query parameters
|
204
80
|
query_params = {}
|
205
81
|
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
|
206
82
|
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
|
207
83
|
query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
|
208
84
|
query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
|
209
85
|
query_params[:'sort_field'] = opts[:'sort_field'] if !opts[:'sort_field'].nil?
|
210
|
-
|
211
|
-
# header parameters
|
212
|
-
header_params = {}
|
213
|
-
# HTTP header 'Accept' (if needed)
|
214
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
215
|
-
# HTTP header 'Content-Type'
|
216
|
-
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
217
|
-
|
218
|
-
# form parameters
|
219
|
-
form_params = {}
|
220
|
-
|
221
|
-
# http body (model)
|
222
86
|
post_body = nil
|
223
|
-
|
87
|
+
|
88
|
+
local_var_path = '/reporting/facebook-ads/{outreach_id}/ecommerce-product-activity'.sub('{' + 'outreach_id' + '}', outreach_id.to_s)
|
224
89
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
225
|
-
:header_params => header_params,
|
226
90
|
:query_params => query_params,
|
227
|
-
:
|
228
|
-
:body => post_body,
|
229
|
-
:auth_names => auth_names,
|
230
|
-
:return_type => 'InlineResponse2008')
|
91
|
+
:body => post_body)
|
231
92
|
return data, status_code, headers
|
232
93
|
end
|
233
|
-
# List landing pages reports
|
234
|
-
# Get reports of landing pages.
|
235
|
-
# @param [Hash] opts the optional parameters
|
236
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
237
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
238
|
-
# @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)
|
239
|
-
# @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)
|
240
|
-
# @return [InlineResponse20013]
|
241
|
-
def get_landing_page_reports_all(opts = {})
|
242
|
-
data, _status_code, _headers = get_landing_page_reports_all_with_http_info(opts)
|
243
|
-
data
|
244
|
-
end
|
245
94
|
|
246
95
|
# List landing pages reports
|
247
|
-
|
248
|
-
|
249
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
250
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
251
|
-
# @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**
|
252
|
-
# @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**.
|
253
|
-
# @return [Array<(InlineResponse20013, Fixnum, Hash)>] InlineResponse20013 data, response status code and response headers
|
254
|
-
def get_landing_page_reports_all_with_http_info(opts = {})
|
255
|
-
# resource path
|
256
|
-
local_var_path = '/reporting/landing-pages'
|
96
|
+
def get_landing_page_reports_all(opts = {})
|
97
|
+
fail ArgumentError, 'invalid value for "opts[:"count"]", must be smaller than or equal to 1000.' if !opts[:'count'].nil? && opts[:'count'] > 1000
|
257
98
|
|
258
|
-
# query parameters
|
259
99
|
query_params = {}
|
260
100
|
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
|
261
101
|
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
|
262
102
|
query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
|
263
103
|
query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].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
104
|
post_body = nil
|
277
|
-
|
105
|
+
|
106
|
+
local_var_path = '/reporting/landing-pages'
|
278
107
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
279
|
-
:header_params => header_params,
|
280
108
|
:query_params => query_params,
|
281
|
-
:
|
282
|
-
:body => post_body,
|
283
|
-
:auth_names => auth_names,
|
284
|
-
:return_type => 'InlineResponse20013')
|
109
|
+
:body => post_body)
|
285
110
|
return data, status_code, headers
|
286
111
|
end
|
287
|
-
# Get landing page report
|
288
|
-
# Get report of a landing page.
|
289
|
-
# @param outreach_id The outreach id.
|
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
|
-
# @return [LandingPageReport]
|
294
|
-
def get_landing_page_report(outreach_id = {}, opts = {})
|
295
|
-
data, _status_code, _headers = get_landing_page_report_with_http_info(outreach_id, opts)
|
296
|
-
data
|
297
|
-
end
|
298
112
|
|
299
113
|
# Get landing page report
|
300
|
-
|
301
|
-
|
302
|
-
# @param [Hash] opts the optional parameters
|
303
|
-
# @option opts [Array<String>] :fields A comma-separated list of fields to return. Reference parameters of sub-objects with dot notation.
|
304
|
-
# @option opts [Array<String>] :exclude_fields A comma-separated list of fields to exclude. Reference parameters of sub-objects with dot notation.
|
305
|
-
# @return [Array<(LandingPageReport, Fixnum, Hash)>] LandingPageReport data, response status code and response headers
|
306
|
-
def get_landing_page_report_with_http_info(outreach_id, opts = {})
|
307
|
-
# resource path
|
308
|
-
local_var_path = '/reporting/landing-pages/{outreach_id}'.sub('{' + 'outreach_id' + '}', outreach_id.to_s)
|
114
|
+
def get_landing_page_report(outreach_id, opts = {})
|
115
|
+
fail ArgumentError, "Missing required param: 'outreach_id'" if outreach_id.nil?
|
309
116
|
|
310
|
-
# query parameters
|
311
117
|
query_params = {}
|
312
118
|
query_params[:'fields'] = @api_client.build_collection_param(opts[:'fields'], :csv) if !opts[:'fields'].nil?
|
313
119
|
query_params[:'exclude_fields'] = @api_client.build_collection_param(opts[:'exclude_fields'], :csv) if !opts[:'exclude_fields'].nil?
|
314
|
-
|
315
|
-
# header parameters
|
316
|
-
header_params = {}
|
317
|
-
# HTTP header 'Accept' (if needed)
|
318
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json'])
|
319
|
-
# HTTP header 'Content-Type'
|
320
|
-
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
321
|
-
|
322
|
-
# form parameters
|
323
|
-
form_params = {}
|
324
|
-
|
325
|
-
# http body (model)
|
326
120
|
post_body = nil
|
327
|
-
|
121
|
+
|
122
|
+
local_var_path = '/reporting/landing-pages/{outreach_id}'.sub('{' + 'outreach_id' + '}', outreach_id.to_s)
|
328
123
|
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
329
|
-
:header_params => header_params,
|
330
124
|
:query_params => query_params,
|
331
|
-
:
|
332
|
-
:body => post_body,
|
333
|
-
:auth_names => auth_names,
|
334
|
-
:return_type => 'LandingPageReport')
|
125
|
+
:body => post_body)
|
335
126
|
return data, status_code, headers
|
336
127
|
end
|
337
128
|
end
|