Skip to main content
GET
cURL
Retrieves aggregated statistics for campaign ambassadors, grouped by individual affiliate. This endpoint provides performance metrics including revenue, commission, order counts, refund amounts, and clicks for ambassadors within a specified date range.

Request Parameters

Request Examples

Basic Request

With Clicks

With Clicks

Response Example

Response Fields

Filter Examples

Search Filter

The search parameter searches across email, first name, last name, and full name:

Email Filter (Single)

Filter by a specific ambassador email:

Email Filter (Multiple - Comma Separated)

Filter by multiple ambassador emails using comma-separated values:

First Name Filter

Filter by ambassador first name (case-insensitive, partial match):

Last Name Filter

Filter by ambassador last name (case-insensitive, partial match):

Combined Filters

You can combine multiple filters:

Pagination

Important Notes

Time Periods

All metrics (revenue, commission, orders, clicks, refunds) are filtered by the specified date range. The start_date and end_date parameters filter tracking events by their occurred_at timestamp (when the sale or click happened), not by when the ambassador joined the campaign. To analyze different time periods, make separate API calls with different date ranges:
  • This Month: start_date=12/01/2024&end_date=12/31/2024
  • Last Month: start_date=11/01/2024&end_date=11/30/2024
  • Year to Date: start_date=01/01/2024&end_date=12/31/2024
  • Custom Range: Any range you specify

Pagination

  • Default: 20 results per page
  • Maximum: 100 results per page
  • Performance: Always use pagination for campaigns with many ambassadors
  • All ambassadors shown: Even ambassadors with 0 sales appear in results if they match filters
  • Use total_pages in the meta response to iterate through all pages

Error Responses

400 Bad Request - Missing Required Parameters

401 Unauthorized - Invalid API Key

429 Too Many Requests - Rate Limit Exceeded

Rate Limiting

This endpoint is subject to the standard Public API rate limits:
  • Frequency Limit: 2-second minimum interval between requests
  • Hourly Limit: 40 requests per hour (default, configurable per organization)

Performance Tips

To ensure fast response times:
  1. Use Pagination: Always paginate for campaigns with many ambassadors
  2. Apply Filters: Use email/name filters to narrow results
  3. Clicks: Only add include_clicks=true when you specifically need click data

Integration Examples

JavaScript/Node.js

Python

Ruby

Filtering Best Practices

Multiple Emails

When filtering by multiple emails, use comma-separated values without spaces (or with spaces - both work):
The system will:
  • Split on commas
  • Trim whitespace
  • Convert to lowercase for case-insensitive matching

Search vs Specific Filters

  • Use search for broad queries across all name/email fields
  • Use email, first_name, or last_name for precise filtering

Including Clicks

By default, clicks are not included to ensure fast response times. To include click data:
Note: Including clicks may increase response time. For optimal performance, combine with specific email filters to limit the number of ambassadors queried.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

start_date
string<date>
default:09/01/2025
required

Start date in MM/DD/YYYY format

end_date
string<date>
default:09/30/2025
required

End date in MM/DD/YYYY format

campaign_id
integer
required

ID of the campaign to query

page
integer
default:1

Page number for pagination. Default is 1.

per_page
integer
default:20

Number of results per page. Default is 20. Maximum is 100.

Required range: x <= 100

Search across email, first name, last name, or full name

email
string<email>

Filter by ambassador email(s). Supports comma-separated values

first_name
string

Filter by ambassador first name (case-insensitive, partial match)

last_name
string

Filter by ambassador last name (case-insensitive, partial match)

status
enum<string>
default:all

Filter by tracking event status

Available options:
all,
paid,
pending,
canceled,
due

Response

Ambassador stats retrieved successfully

data
object[]
meta
object