Query Parameters
Number of results per page. Minimum value is 1, maximum value is 100. Default is 10.
Cursor for pagination. Use the id of the last item from the previous page to get the next page.
Cursor for pagination. Use the id of the first item from the current page to get the previous page.
Filter referrals by affiliate ID. Only returns referrals for the specified affiliate.
Sort order. Valid values: asc, desc. Defaults to desc (newest first).
Filter referrals by status. Valid values: lead, trialing, customer, active, canceled, rejected. Note: click status is excluded from this endpoint.
Filter referrals created on or after this date. ISO 8601 date-time format (e.g., 2024-01-01T00:00:00Z).
Filter referrals created on or before this date. ISO 8601 date-time format (e.g., 2024-12-31T23:59:59Z).
Comma-separated list of related data to include. Valid values: affiliate. Example: expand=affiliate.
Response
The response includes a cursor-paginated list of referrals.
Always true for successful responses
Array of referral objects. Each referral object has the same structure as the single referral response (see Get Referral endpoint).Show Data Object Properties
Unique identifier for the referral
The affiliate ID who referred this customer
The customer’s email address
Your internal customer ID if provided
Your internal subscription ID if provided
The referral status (lowercase): lead, trialing, customer, active, canceled, rejected
ISO 8601 timestamp of when the referral was created
ISO 8601 timestamp of when the referral was converted (set when status is not lead)
Whether there are more results available
curl -X GET "https://api.affonso.io/v1/referrals?limit=10&status=customer" \
-H "Authorization: Bearer sk_live_your_api_key"
{
"success": true,
"data": [
{
"id": "ref_abc123",
"affiliate_id": "aff_456def",
"program_id": "prg_789ghi",
"email": "[email protected]",
"customer_id": "cust_123",
"subscription_id": null,
"status": "customer",
"created_at": "2024-01-20T15:30:00Z",
"converted_at": "2024-01-20T15:30:00Z"
}
],
"has_more": true
}