Skip to main content
GET
List campaign performance

Authorizations

Authorization
string
header
required

Send either an API token or an OAuth access token as Authorization: Bearer <token>. See the Authentication page for details.

Headers

Privy-Account-Id
string

Target a subaccount instead of the main connected account. Pass a subaccount id from get_account's subaccounts list. Only direct subaccounts of the connected account are reachable — omit this for the main account itself.

Query Parameters

period
enum<string>
default:last_30_days

The date range to report over, resolved in the account's time zone. Pass custom together with start_date and end_date.

Available options:
last_7_days,
last_30_days,
last_90_days,
this_month,
last_month,
custom
start_date
string<date>

Inclusive start of a custom period (ISO 8601 date). Required when period=custom, ignored otherwise.

end_date
string<date>

Inclusive end of a custom period (ISO 8601 date). Required when period=custom, ignored otherwise. Custom periods are capped at 366 days.

type
enum<string>

Pass flows to rank the messages your flows send instead of newsletters.

Available options:
flows
channel
enum<string>

Filter by message channel. Works for both newsletters and flow campaigns.

Available options:
email,
sms
page
integer
default:1

Page number (starts at 1).

Required range: x >= 1
per_page
integer
default:10

Campaigns per page. Values above 50 are clamped to 50; omitted or invalid values default to 10.

Required range: 1 <= x <= 50

Response

Campaigns ranked by attributed revenue over the resolved period.

data
object[]
period
object

The resolved date range the report covers, inclusive, in the account's time zone. Every label except last_month ends today, so the last day of the range is still in progress: last_7_days is the six days before today plus today, this_month runs from the 1st through today, and last_month is the whole previous calendar month. Custom ranges cannot exceed 366 days.

pagination
object