Export audience activity CSV
Export audience activity CSV
Export a compressed CSV report of audience-level delivery and engagement data for a specific message. This includes sent, delivered, clicked, failed, and unsubscribed events across Push, Email, and SMS channels.
POST
Export audience activity CSV
Documentation Index
Fetch the complete documentation index at: https://documentation.onesignal.com/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Get a CSV of per-recipient audience activity events (sends, clicks, failures, etc.) for a push, email, or SMS message. This endpoint mirrors the Export button in the dashboard’s Audience Activity section on each message report: The CSV schema varies by channel. See each channel’s message reports page for column definitions.How to use this API
Get the messageid from the Sending messages API or the View messages API.
A successful request returns 200 OK with a csv_file_url:
200 OK
events_audience-activity-{message_id}-{channel}-{timestamp}.csv.gz.
The file is generated at ~2,000 records per second. For large audiences, generation can take several minutes, and the URL may return 404 until the file is ready:
404 Not Found
csv_file_url with GET and implement retries with exponential backoff. When the file is ready, the GET request downloads the .csv.gz file.
- The CSV download URL is valid for 3 days after creation.
- File names include a random UUID to prevent guessing.
Headers
Your App API key with prefix Key. See Keys & IDs.
Path Parameters
The identifier of the message in UUID v4 format. Get this id in the response of your Create Message API request, the View Messages API, and in your OneSignal dashboard Message Reports.
Query Parameters
Your OneSignal App ID in UUID v4 format. See Keys & IDs.
Response
200
The URL to download the CSV file. The file is available for 3 days after generation.