Class: MailchimpTransactional::ExportsApi

Inherits:
Object
  • Object
show all
Defined in:
lib/MailchimpTransactional/api/exports_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ ExportsApi

Returns a new instance of ExportsApi.



19
20
21
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 19

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#activity(body = {}) ⇒ Array<(InlineResponse2007, Fixnum, Hash)>

Export activity history Begins an export of your activity history. The activity will be exported to a zip archive containing a single file named activity.csv in the same format as you would be able to export from your account&#39;s activity view. It includes the following fields: Date, Email Address, Sender, Subject, Status, Tags, Opens, Clicks, Bounce Detail. If you have configured any custom metadata fields, they will be included in the exported data.

Parameters:

  • body (defaults to: {})
  • opts (Hash)

    the optional parameters

Returns:

  • (Array<(InlineResponse2007, Fixnum, Hash)>)

    InlineResponse2007 data, response status code and response headers



28
29
30
31
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 28

def activity(body = {})
  data = @api_client.call_api(:POST, '/exports/activity', body)
  data
end

#allowlist(body = {}) ⇒ Array<(InlineResponse2006, Fixnum, Hash)>

Export Allowlist Begins an export of your rejection allowlist. The allowlist will be exported to a zip archive containing a single file named allowlist.csv that includes the following fields: email, detail, created_at.

Parameters:

  • body (defaults to: {})
  • opts (Hash)

    the optional parameters

Returns:

  • (Array<(InlineResponse2006, Fixnum, Hash)>)

    InlineResponse2006 data, response status code and response headers



38
39
40
41
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 38

def allowlist(body = {})
  data = @api_client.call_api(:POST, '/exports/allowlist', body)
  data
end

#info(body = {}) ⇒ Array<(InlineResponse2003, Fixnum, Hash)>

View export info Returns information about an export job. If the export job&#39;s state is &#39;complete&#39;, the returned data will include a URL you can use to fetch the results. Every export job produces a zip archive, but the format of the archive is distinct for each job type. The api calls that initiate exports include more details about the output format for that job type.

Parameters:

  • body (defaults to: {})
  • opts (Hash)

    the optional parameters

Returns:

  • (Array<(InlineResponse2003, Fixnum, Hash)>)

    InlineResponse2003 data, response status code and response headers



48
49
50
51
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 48

def info(body = {})
  data = @api_client.call_api(:POST, '/exports/info', body)
  data
end

#list(body = {}) ⇒ Array<(Array<InlineResponse2004>, Fixnum, Hash)>

List exports Returns a list of your exports.

Parameters:

  • body (defaults to: {})
  • opts (Hash)

    the optional parameters

Returns:

  • (Array<(Array<InlineResponse2004>, Fixnum, Hash)>)

    Array<InlineResponse2004> data, response status code and response headers



58
59
60
61
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 58

def list(body = {})
  data = @api_client.call_api(:POST, '/exports/list', body)
  data
end

#rejects(body = {}) ⇒ Array<(InlineResponse2005, Fixnum, Hash)>

Export denylist Begins an export of your rejection denylist. The denylist will be exported to a zip archive containing a single file named rejects.csv that includes the following fields: email, reason, detail, created_at, expires_at, last_event_at, expires_at.

Parameters:

  • body (defaults to: {})
  • opts (Hash)

    the optional parameters

Returns:

  • (Array<(InlineResponse2005, Fixnum, Hash)>)

    InlineResponse2005 data, response status code and response headers



68
69
70
71
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 68

def rejects(body = {})
  data = @api_client.call_api(:POST, '/exports/rejects', body)
  data
end

#whitelist(body = {}) ⇒ Array<(InlineResponse2006, Fixnum, Hash)>

Export Allowlist Begins an export of your rejection allowlist. The allowlist will be exported to a zip archive containing a single file named allowlist.csv that includes the following fields: email, detail, created_at.

Parameters:

  • body (defaults to: {})
  • opts (Hash)

    the optional parameters

Returns:

  • (Array<(InlineResponse2006, Fixnum, Hash)>)

    InlineResponse2006 data, response status code and response headers



78
79
80
81
# File 'lib/MailchimpTransactional/api/exports_api.rb', line 78

def whitelist(body = {})
  data = @api_client.call_api(:POST, '/exports/whitelist', body)
  data
end