Reports
Discovery for the reports API: each of the six report types with the filters it accepts (names, data types, options), its result datasets and columns, grouping options, and the relative_date presets. Call this before create_report to construct a valid report.
Report types: affiliate_performance, attribution_performance, checkout_performance, customer_cohort_ltv, payment_plan_performance, product_sales.
Filter note: static options arrays are included where available. Dynamic / account-specific options (e.g. product lists, checkout lists) are omitted from this endpoint — pass the lister object's object field to understand what entity type drives the search.
Note: reports bucket dates in the report's own timezone field (legacy semantics), unlike /v2/analytics which is UTC-only.
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Successful response
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Internal Server Error - An unexpected error occurred
GET /v2/reports/types HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"type": "text",
"label": "text",
"filters": [
{
"name": "text",
"data_type": "text",
"options": [
{
"id": null,
"label": "text"
}
]
}
],
"datasets": [
{
"type": "text",
"display_type": "text",
"grouping_properties": [
"text"
],
"grouping_intervals": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"columns": [
{
"name": "text",
"label": "text",
"data_type": "text"
}
]
}
],
"relative_dates": [
"text"
]
}Streams the full dataset for a completed run as text/csv, with no pagination and no row cap.
This endpoint requires no authentication — the signed token in the path is the credential — and it does not count against your monthly API quota. It is the cheapest way to pull a large dataset: create the run, poll until it completes, mint a URL with POST /v2/reports/{report_id}/runs/{run_id}/exports, then download here.
Tokens expire 15 minutes after they are minted.
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Signed download token from the create-export response
Successful response
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Not Found - The requested resource does not exist
Internal Server Error - An unexpected error occurred
GET /v2/reports/exports/{token} HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
No content
List saved reports
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Page number
1Items per page (max 100)
25Filter by type (exact match).
Filter by type (contains)
Filter by is_active (exact match). Valid values: true, false.
Filter by is_active (comma-separated list). Fetches many records in one request instead of one request per id.
true,falseFilter by is_active (excluding a comma-separated list)
Filter by created_at (exact match).
Filter by created_at (greater than or equal)
Filter by created_at (less than or equal)
Sort field (prefix with - for descending)
-created_atSuccessful response with paginated list
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Internal Server Error - An unexpected error occurred
GET /v2/reports HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"data": [
{
"id": 1,
"type": "text",
"name": "text",
"filters": [
{
"name": "text",
"comparison": "text",
"values": [],
"value": null
}
],
"timezone": "text",
"relative_date": "text",
"frequency": "day",
"frequency_count": 1,
"next_run_at": "2026-01-01T00:00:00.000Z",
"is_active": true,
"users": [
{
"user_id": 1,
"name": "text",
"email": "text"
}
],
"created_at": "2026-01-01T00:00:00.000Z",
"updated_at": "2026-01-01T00:00:00.000Z"
}
],
"pagination": {
"page": 1,
"limit": 25,
"total": 150,
"pages": 6
}
}Create a new saved report. Call GET /v2/reports/types (list_report_types) first to discover valid type values, filter names, and relative_date presets.
Scheduling: when frequency and relative_date are set, the report is emailed to its users on the computed schedule — exactly as dashboard-created scheduled reports are. frequency requires relative_date (a rolling window such as "Last Month"). users[] is optional — each entry takes {user_id} OR {email} (account users with report access). When scheduling and users is omitted, it defaults to YOU (the authorizing user), so "schedule this and email me" needs no ids at all.
next_run_at is computed automatically from frequency + frequency_count; do not set it manually.
Reports are created active (is_active=true, no draft state — unlike the dashboard). When name is omitted, a descriptive name is auto-generated from the type and filters (same as the dashboard) — but pass an explicit name when you want a predictable one.
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Created successfully
Report type key, e.g. 'product_sales'. See GET /v2/reports/types.
IANA timezone the report buckets dates in (legacy semantics — unlike /v2/analytics, which is UTC-only).
Date-range preset resolved per run, e.g. 'Last Month'.
Bad Request - The request was invalid or malformed
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Conflict - The request conflicts with the current state of the resource
Internal Server Error - An unexpected error occurred
POST /v2/reports HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 220
{
"type": "text",
"name": "text",
"filters": [
{
"name": "text",
"comparison": "text",
"values": [],
"value": null
}
],
"timezone": "text",
"relative_date": "text",
"frequency": "day",
"frequency_count": 1,
"users": [
{
"user_id": 1,
"email": "text"
}
]
}{
"id": 1,
"type": "text",
"name": "text",
"filters": [
{
"name": "text",
"comparison": "text",
"values": [],
"value": null
}
],
"timezone": "text",
"relative_date": "text",
"frequency": "day",
"frequency_count": 1,
"next_run_at": "2026-01-01T00:00:00.000Z",
"is_active": true,
"users": [
{
"user_id": 1,
"name": "text",
"email": "text"
}
],
"created_at": "2026-01-01T00:00:00.000Z",
"updated_at": "2026-01-01T00:00:00.000Z"
}Retrieve a single reports by ID
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
reports ID
12345Successful response
Report type key, e.g. 'product_sales'. See GET /v2/reports/types.
IANA timezone the report buckets dates in (legacy semantics — unlike /v2/analytics, which is UTC-only).
Date-range preset resolved per run, e.g. 'Last Month'.
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Not Found - The requested resource does not exist
Internal Server Error - An unexpected error occurred
GET /v2/reports/{report_id} HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"id": 1,
"type": "text",
"name": "text",
"filters": [
{
"name": "text",
"comparison": "text",
"values": [],
"value": null
}
],
"timezone": "text",
"relative_date": "text",
"frequency": "day",
"frequency_count": 1,
"next_run_at": "2026-01-01T00:00:00.000Z",
"is_active": true,
"users": [
{
"user_id": 1,
"name": "text",
"email": "text"
}
],
"created_at": "2026-01-01T00:00:00.000Z",
"updated_at": "2026-01-01T00:00:00.000Z"
}Soft-delete a saved report (sets is_active=false). The report is no longer returned by the default list. Returns 204 on success.
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Report ID
Deleted successfully
No content
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Not Found - The requested resource does not exist
Internal Server Error - An unexpected error occurred
DELETE /v2/reports/{report_id} HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
No content
Update an existing saved report. Only the provided fields are changed (partial update). Set name, relative_date, frequency, or frequency_count to null to clear them — clearing frequency turns the schedule off (next_run_at becomes null). Set is_active=true to reactivate a soft-deleted report. Supplying users replaces the entire recipient list ({user_id} or {email} per entry; [] clears it); when a patch introduces frequency on a report with no recipients and users is omitted, the authorizing user is defaulted. Changing the cadence recomputes next_run_at; resending an unchanged frequency leaves the send date where it is.
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Report ID
Report name. null clears the name.
Date-range preset, e.g. 'Last Month'. null clears the schedule window (only valid when frequency is also null/cleared).
Schedule frequency. null clears the schedule (next_run_at becomes null).
Schedule interval multiplier. null clears it (treated as 1 while frequency is set).
true reactivates a soft-deleted report; false soft-deletes (same as DELETE).
Successful response
Report type key, e.g. 'product_sales'. See GET /v2/reports/types.
IANA timezone the report buckets dates in (legacy semantics — unlike /v2/analytics, which is UTC-only).
Date-range preset resolved per run, e.g. 'Last Month'.
Bad Request - The request was invalid or malformed
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Not Found - The requested resource does not exist
Conflict - The request conflicts with the current state of the resource
Internal Server Error - An unexpected error occurred
PATCH /v2/reports/{report_id} HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 223
{
"name": "text",
"filters": [
{
"name": "text",
"comparison": "text",
"values": [],
"value": null
}
],
"timezone": "text",
"relative_date": "text",
"frequency": "day",
"frequency_count": 1,
"users": [
{
"user_id": 1,
"email": "text"
}
],
"is_active": true
}{
"id": 1,
"type": "text",
"name": "text",
"filters": [
{
"name": "text",
"comparison": "text",
"values": [],
"value": null
}
],
"timezone": "text",
"relative_date": "text",
"frequency": "day",
"frequency_count": 1,
"next_run_at": "2026-01-01T00:00:00.000Z",
"is_active": true,
"users": [
{
"user_id": 1,
"name": "text",
"email": "text"
}
],
"created_at": "2026-01-01T00:00:00.000Z",
"updated_at": "2026-01-01T00:00:00.000Z"
}List runs for a report
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Page number
1Items per page (max 100)
25Sort field (prefix with - for descending)
-created_atSuccessful response with paginated list
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Internal Server Error - An unexpected error occurred
GET /v2/reports/{report_id}/runs HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"data": [
{
"id": 1,
"report_id": 1,
"status": "pending",
"start_at": "2026-01-01T00:00:00.000Z",
"end_at": "2026-01-01T00:00:00.000Z",
"started_at": "2026-01-01T00:00:00.000Z",
"completed_at": "2026-01-01T00:00:00.000Z",
"error_reason": "text",
"stats": {
"flat_stats": {
"ANY_ADDITIONAL_PROPERTY": {
"value": 1,
"label": "text",
"data_type": "text"
}
}
},
"created_at": "2026-01-01T00:00:00.000Z"
}
],
"pagination": {
"page": 1,
"limit": 25,
"total": 150,
"pages": 6
}
}Create a new report run. Returns 202 Accepted with the run in "pending" status. Execution is asynchronous: a background worker picks up pending runs, so runs typically START within about 30 seconds of creation, then take a few seconds to a few minutes to finish depending on data volume.
Polling: call get_report_run until status is "completed" or "failed". Each poll counts against the monthly API quota — poll no faster than every ~30 seconds (matches the worker pickup cadence); typical runs complete within a couple of minutes.
Reading results: when completed, the run includes a stats block (flat_stats) that answers most questions — total revenue, count, etc. — without fetching rows. Read stats first; only fetch rows via list_report_run_results if you need detail.
The run inherits the report's filters, timezone, and date range. For relative_date presets (e.g. "Last Month"), the start/end dates are resolved at run time. The report must have a date range — relative_date or a report_date filter — or this returns 400 (every report type date-filters its results).
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Report ID
Created successfully
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Not Found - The requested resource does not exist
Conflict - The request conflicts with the current state of the resource
Internal Server Error - An unexpected error occurred
POST /v2/reports/{report_id}/runs HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"id": 1,
"report_id": 1,
"status": "pending",
"start_at": "2026-01-01T00:00:00.000Z",
"end_at": "2026-01-01T00:00:00.000Z",
"started_at": "2026-01-01T00:00:00.000Z",
"completed_at": "2026-01-01T00:00:00.000Z",
"error_reason": "text",
"stats": {
"flat_stats": {
"ANY_ADDITIONAL_PROPERTY": {
"value": 1,
"label": "text",
"data_type": "text"
}
}
},
"created_at": "2026-01-01T00:00:00.000Z"
}Retrieve a single reports by ID
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Successful response
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Not Found - The requested resource does not exist
Internal Server Error - An unexpected error occurred
GET /v2/reports/{report_id}/runs/{run_id} HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"id": 1,
"report_id": 1,
"status": "pending",
"start_at": "2026-01-01T00:00:00.000Z",
"end_at": "2026-01-01T00:00:00.000Z",
"started_at": "2026-01-01T00:00:00.000Z",
"completed_at": "2026-01-01T00:00:00.000Z",
"error_reason": "text",
"stats": {
"flat_stats": {
"ANY_ADDITIONAL_PROPERTY": {
"value": 1,
"label": "text",
"data_type": "text"
}
}
},
"created_at": "2026-01-01T00:00:00.000Z"
}Get paginated tabular results for a completed report run
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Page number
1Items per page (max 100)
25Sort field (prefix with - for descending)
-created_atSuccessful response with paginated list
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Internal Server Error - An unexpected error occurred
GET /v2/reports/{report_id}/runs/{run_id}/results HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"data": [
{
"dataset": "text",
"columns": [
{
"name": "text",
"label": "text",
"data_type": "text"
}
],
"rows": [
[]
]
}
],
"pagination": {
"page": 1,
"limit": 25,
"total": 150,
"pages": 6
}
}Generates a signed download URL for the full dataset of a completed run. One quota call, zero context — the URL is handed to the user or fetched with local tooling (e.g. curl). The URL requires no authentication (the signed token IS the credential). Expires in 15 minutes.
Run must be completed (status=completed) — 409 otherwise; poll get_report_run first.
Query/body param: dataset — which dataset to download (default: "default"); 400 lists available datasets.
Response: { data: { url: string, expires_at: ISO8601 } }
Account API key authentication. Pass an API key as a Bearer token in the Authorization header. An account may have multiple named keys; any of them grants full access to all endpoints — equivalent to all OAuth scopes.
Report ID
Run ID
Created successfully
Short-lived signed download URL for the full CSV. No authentication needed; expires quickly.
Unauthorized - Authentication is required or has failed
Forbidden - You do not have permission to access this resource
Not Found - The requested resource does not exist
Conflict - The request conflicts with the current state of the resource
Internal Server Error - An unexpected error occurred
POST /v2/reports/{report_id}/runs/{run_id}/exports HTTP/1.1
Host: api.spiffy.co
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"url": "text",
"expires_at": "2026-01-01T00:00:00.000Z"
}Last updated