This API handles fetching wholesale category discounts.
/wp-json/wholesale/v1/category-discount
Postman
List all category with wholesale discounts:
GET: /wp-json/wholesale/v1/category-discount
Status: 200 OK
List all category with wholesale discounts
GET: /wp-json/wholesale/v1/category-discount
Response:
[
{
"id": 15,
"name": "Uncategorized",
"wholesale_discounts": {
"wholesale_customer_wholesale_discount": 123,
"WholesaleBronze_wholesale_discount": 0
}
},
{
"id": 30,
"name": "Wholesale",
"wholesale_discounts": {
"wholesale_customer_wholesale_discount": 10,
"WholesaleBronze_wholesale_discount": 20
}
},
{
"id": 697,
"name": "Accessories",
"wholesale_discounts": {
"wholesale_customer_wholesale_discount": 0,
"WholesaleBronze_wholesale_discount": 0
}
}
]