v1.0.0
OpenAPI 3.1.0

Export information about deliveries

US region

Client Libraries

Export information about deliveries

Provide filters for the one-time send, automation, or action you want to return delivery information from. This endpoint starts an export, but you cannot download your export from this endpoint. Use the /exports/{export_id} endpoint to download your export.

Use the start and end to find messages within a time range. If your request doesn't include start and end parameters, we'll return the most recent 6 months of messages. If your start and end range is more than 12 months, we'll return 12 months of data from the most recent timestamp in your request. Timestamps reflect when deliveries were created in our system, not when they were actually sent to recipients. There may be a delay between creation and sending.

Body
application/json
  • Contains properties shared by export filters.

    • newsletter_id
      Type: integer
      required

      The ID of a one-time send you want to export information from.

    • attributes
      Type: array string[]

      Recipient attributes you want to include as extra columns in your export. You can't include event or trigger properties.

    • drafts
      Type: boolean

      If true, your request returns both drafts and active/sent messages.

    • end
      Type: integer Format: unix timestamp

      The unix timestamp representing the end of the export.

    • metric
      Type: string enum

      Determines the metric(s) you want to return.

      values
      • created
      • attempted
      • sent
      • delivered
      • opened
    • start
      Type: integer Format: unix timestamp

      The unix timestamp representing the beginning of the export.

    • template_id
      Type: integer

      Restrict the export to a specific message template (content) within the selected automation, one-time send, or transactional message.

Responses
  • application/json
  • 400

    The request is malformed.

  • application/json
Request Example for post/v1/exports/deliveries
{
  "newsletter_id": 999,
  "attributes": [
    ""
  ],
  "drafts": true,
  "end": 1517702400,
  "metric": "created",
  "start": 1517529600,
  "template_id": 1
}
{
  "export": {
    "created_at": 1530296742,
    "deduplicate_id": "110:1530296738",
    "description": "Full deliveries export (created via the api)",
    "downloads": 0,
    "failed": false,
    "id": "111,",
    "type": "deliveries",
    "updated_at": 1530296742
  }
}