curl --request GET \
--url https://api.sprucecollective.co.uk/reports/returning-customers \
--header 'Authorization: <api-key>'{
"customers": [
{
"average_order_value": 123,
"customer_lifetime_value": 123,
"days_between_purchases": 123,
"email": "<string>",
"first_name": "<string>",
"first_purchase_date": "<string>",
"is_active": true,
"last_name": "<string>",
"last_purchase_date": "<string>",
"purchase_frequency": 123,
"total_spent_cents": 123,
"total_spent_dollars": 123,
"total_transactions": 123,
"user_id": "<string>"
}
],
"summary": {
"active_returning_customers": 123,
"average_customer_lifetime_value": 123,
"average_days_between_purchases": 123,
"average_purchase_frequency": 123,
"top_spender": {
"email": "<string>",
"total": 123
},
"total_returning_customers": 123,
"total_revenue_from_returning": 123
}
}Returns detailed analysis of customers who have made multiple purchases, including lifetime value, frequency, and recency metrics
curl --request GET \
--url https://api.sprucecollective.co.uk/reports/returning-customers \
--header 'Authorization: <api-key>'{
"customers": [
{
"average_order_value": 123,
"customer_lifetime_value": 123,
"days_between_purchases": 123,
"email": "<string>",
"first_name": "<string>",
"first_purchase_date": "<string>",
"is_active": true,
"last_name": "<string>",
"last_purchase_date": "<string>",
"purchase_frequency": 123,
"total_spent_cents": 123,
"total_spent_dollars": 123,
"total_transactions": 123,
"user_id": "<string>"
}
],
"summary": {
"active_returning_customers": 123,
"average_customer_lifetime_value": 123,
"average_days_between_purchases": 123,
"average_purchase_frequency": 123,
"top_spender": {
"email": "<string>",
"total": 123
},
"total_returning_customers": 123,
"total_revenue_from_returning": 123
}
}Type "Bearer" followed by a space and JWT token.
Start date (YYYY-MM-DD)
End date (YYYY-MM-DD)
Last X days (default: 90)
Site ID for multi-tenant filtering
Minimum number of transactions to be considered returning (default: 2)
Maximum number of customers to return (default: 100, max: 500)
OK
Show child attributes
purchased in last 30 days
purchases per month
Show child attributes