Skip to main content
POST
Export an ad-hoc audience as CSV

Authorizations

Authorization
string
header
required

Dashboard JWT token from Clerk

Body

application/json
filters
object
required

The audience definition — the same FilterAst the segment builder and auto-suggest speak (a single condition or a nested AND/OR group). Validated server-side against the field allowlist + depth cap.

limit
integer

Optional row cap below the 50,000-row hard ceiling (e.g. for a quick sample). Clamped server-side.

Required range: 1 <= x <= 50000
filename
string

Optional filename stem for the download. Sanitised so it cannot break the Content-Disposition header.

Maximum string length: 120

Response

200 - text/csv

RFC-4180 CSV download (Content-Disposition: attachment). One row per matched contact, with a header row: contact_id, first_name, last_name, email, phone, country_code, lifecycle_stage, tags, created_at.

One flat row per matched contact, with a header row.