Skip to main content
POST
/
v1
/
exports
Export Logs
curl --request POST \
  --url https://api.unosend.co/v1/exports \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "type": "<string>",
  "from_date": "<string>",
  "to_date": "<string>",
  "domain": "<string>"
}
'

Documentation Index

Fetch the complete documentation index at: https://docs.unosend.co/llms.txt

Use this file to discover all available pages before exploring further.

Create an export job to download email delivery data in CSV format.
type
string
required
Type of export: email_logs, bounces, suppressions, or opens.
from_date
string
required
Start date in ISO 8601 format.
to_date
string
required
End date in ISO 8601 format.
domain
string
Filter by sending domain. Optional.

Request

cURL
curl -X POST https://api.unosend.co/v1/exports \
  -H "Authorization: Bearer un_xxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "type": "email_logs",
    "from_date": "2026-01-01T00:00:00Z",
    "to_date": "2026-01-31T23:59:59Z"
  }'

Response

202
{
  "message": "Export job created",
  "data": {
    "export_id": "exp_abc123",
    "type": "email_logs",
    "status": "processing",
    "created_at": "2026-01-15T10:30:00.000Z"
  }
}

List Exports

Fetch all export jobs and their statuses.
cURL
curl -X GET https://api.unosend.co/v1/exports \
  -H "Authorization: Bearer un_xxxxxxxxxx"

Response

200
{
  "data": [
    {
      "export_id": "exp_abc123",
      "type": "email_logs",
      "status": "completed",
      "download_url": "https://api.unosend.co/v1/exports/exp_abc123/download",
      "created_at": "2026-01-15T10:30:00.000Z",
      "expires_at": "2026-01-22T10:30:00.000Z"
    }
  ]
}

Download Export

Download a completed export file.
cURL
curl -X GET https://api.unosend.co/v1/exports/exp_abc123/download \
  -H "Authorization: Bearer un_xxxxxxxxxx" \
  -o email_logs.csv
Export download links expire after 7 days. Create a new export if the link has expired.

Delete Export

Delete one or more completed exports.
cURL
curl -X DELETE "https://api.unosend.co/v1/exports?export_ids=exp_abc123,exp_def456" \
  -H "Authorization: Bearer un_xxxxxxxxxx"

Response

200
{
  "message": "Exports deleted",
  "deleted": ["exp_abc123", "exp_def456"]
}