Skip to main content

Data Exports

Export email logs, metrics, and analytics data from Motorical.

Quick Preview

Get a lightweight preview of recent logs without creating a background job:

curl -H "Authorization: Bearer $TOKEN" \
"$BASE_URL/motor-blocks/$BLOCK_ID/exports/preview?limit=100"

Parameters:

ParameterDescription
limitMax records (default 100, max 500)
includePIItrue/false (requires logs.pii scope)

Background Export Jobs

For larger exports, create a background job that generates an NDJSON download:

curl -sS -H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"jobType":"logs"}' \
"$BASE_URL/motor-blocks/$BLOCK_ID/exports"

When the job completes, a signed download URL is issued for the NDJSON file.

Export Formats

FormatUse Case
NDJSONMachine-readable, streaming-friendly
CSVAvailable for Communications Block contact exports
JSONGDPR data portability exports

Communications Block Exports

Contact List Export

Download complete contact lists:

GET /comm-api/api/lists/{id}/contacts/export
X-Tenant-Id: your-tenant-uuid

GDPR Data Export

Comprehensive per-contact data export including profile, campaign history, tracking events, and suppression status. Delivered via email as JSON and CSV attachments.

Best Practices

  • Use preview exports for quick debugging
  • Schedule background exports for large datasets
  • Store exports securely — they may contain PII
  • Set appropriate includePII flags based on your compliance needs
  • Monitor export job status via the API