Customers
/loyalty-program/v1/customers
GET: /wp-json/wc-loyalty-program/v1/customers
GET: http://example.com/wp-json/wc-loyalty-program/v1/customersGET: http://example.com/wp-json/wc-loyalty-program/v1/customers?search=dummy[
...
{
"id": 17,
"name": "John Smith",
"email": "johnsmith@example.com",
},
...
}{
"code": "rest_forbidden_context",
"message": "Sorry, you are not allowed access to this endpoint.",
"data": {
"status": 401
}
}GET: /wp-json/wc-loyalty-program/v1/customers/status/{user_id}
GET: http://example.com/wp-json/wc-loyalty-program/v1/customers/status/17{
"status": [
{
"label": "Total Points (All Time)",
"points": 61,
"value": "$6.10"
},
{
"label": "Unclaimed Points",
"points": 61,
"value": "$6.10"
},
{
"label": "Claimed Points",
"points": 0,
"value": "$0.00"
},
{
"label": "Expired Points",
"points": 0,
"value": "$0.00"
}
],
"sources": [
{
"label": "Purchasing products",
"points": 61
},
{
"label": "Leaving a product review",
"points": 0
},
{
"label": "Commenting on a blog post",
"points": 0
},
{
"label": "Registering as a user/customer",
"points": 0
},
{
"label": "After completing first order",
"points": 0
},
{
"label": "Spending over a certain amount",
"points": 0
},
{
"label": "Extra points during a period",
"points": 0
}
]
}​GET: /wp-json/wc-loyalty-program/v1/customers/history/{user_id}
POST: /wp-json/wc-loyalty-program/v1/customers/points/{user_id}
Last updated