Skip to main content

Query parameters reference

Written by Dariy

All parameters are query-string parameters on GET https://app.statsdrone.com/user/reports.

Required

Parameter

Format

Notes

apiKey

string

Your API key from Settings

dateFrom

YYYY-MM-DD

First day of the period

dateTo

YYYY-MM-DD

Last day of the period, included

reportType

daily or monthly

Exactly these two values

groupBy

see below

Which report to return

groupBy accepts: accounts, brands, campaigns, variables, players, geo, postbacks. Anything else is rejected. variables and postbacks accept reportType=daily only.

Optional

Parameter

Format

Default

Notes

reportCurrency

ISO 4217 code, e.g. EUR

empty

Empty means every account keeps its own currency

tags

comma-separated names

empty

Empty means no tag filter

matchAny

true or false

true

true = any selected tag; false = all of them

labels

labels=true

off

Return your own brand/campaign labels instead of the program's names

Notes on the optional four:

  • reportCurrency must be a currency StatsDrone knows — the same list the Report currency dropdown offers. Converted amounts are rounded to 2 decimal places. If no exchange rate is available for an account's own currency, that account is not converted and its info.currency keeps naming the currency the numbers are actually in. Always read info.currency rather than assuming the currency you asked for.

  • tags filters on account tags for the Accounts, Dynamic Variables, Players, Geo and Postbacks reports, and on brand/campaign tags for the Brands and Campaigns reports. Send tag names with spaces removed.

  • matchAny — any value other than the literal false behaves as true.

  • labels applies to the Brands, Campaigns, Accounts, Dynamic Variables, Players and Geo reports. The Postbacks report ignores it: a postback's brand and campaign are values the affiliate program sent with the event, not names StatsDrone scraped, so there is nothing to relabel.

Date range limits

How far back. Both dates must be within the history your plan includes:

Plan

History available

Freemium

last 12 months

Starter

last 24 months

Pro

last 36 months

Enterprise, Custom, Dev, Trial

last 48 months

These are the defaults. If your plan has been set up with its own history allowance, that one applies

instead — the Settings query builder and the API both use it.


A date outside that window is refused with an error naming the earliest date you can use.

How much at once. There is no page size and no limit parameter — one request returns one whole report. Instead there is a ceiling on the work a single request may do. A request that takes too long to build, or whose response would be very large, is refused with:

Your request exceeds the maximum data limit. Please split the date range into smaller periods.

If you hit it, ask for a shorter period and make several calls. The usual culprits are multi-month Players, Geo and Dynamic Variables requests on accounts with a lot of traffic.

Dates, times and time zones

  • dateFrom and dateTo are calendar dates, and both ends are included.

  • Report dates are the dates the affiliate program reported the activity under. StatsDrone does not shift them into another time zone.

  • On the Postbacks report, dateFrom/dateTo cover whole days: from 00:00:00 on the start date to 23:59:59 on the end date.

Did this answer your question?