GET
/api/v1/customer/earning-history
This API method will retrieve earning-history for the current customer.
If you wanted to get a list specific from source customer (who earned team points, etc), you can pass in customer_id. If you wanted to get a list specific to a campaign, you can pass in campaign_id.
You can also provide both to get a filtered list by campaign and customer sources.
Request Parameters
Parameter | Value / Type | Required |
|---|---|---|
per_page | INTEGER (DEFAULT 50) | false |
page | INTEGER (DEFAULT 1) | false |
customer_id | STRING | false |
campaign_id | STRING | false |
store_id | STRING | false |
date | DATE (Y-m-d) | false |
Sample Response
{
"status": true,
"items": [
{
"id": "2qMAbl7VEqQEnXgQD8pR",
"store_id": "l6yYk1WOeo7e2b78dD4j",
"store_name": "Store A",
"customer_id": "LZWBJx0PmYkEwjGdr2vO",
"customer_name": "John Smith",
"campaign_id": "l6yYk1WOeo7e2b78dD4j",
"campaign_name": "New Campaign",
"reference_customer_id": "l6yYk1WOeo7e2b78dD4j",
"reference_customer_name": "Phil Collins",
"reference_customer_avatar":"http:\/\/controlcenter.ftx\/images\/avatars\/128x128\/14.jpg?v=1528194577",
"balance_type": "Default",
"location_id": "Ol2GJkRbElpEA53xM8B1",
"bonus_type": "CampaignPoints",
"notes": "Swag Item Purchase",
"balance_added": "40.00",
"created_at": "2017-05-01 17:06:10"
}
]
}