Reputation: 111
I am trying to integrate the woocommerce rest apis with my app. All the defaults operations like create/update product, get all products, get products by category etc are working perfectly fine. However filtering product results based on some chosen filters are not working. For example if I want to filter products with color=Red and brand=Arrow then the api doesn't work.
Can someone please let me know how are product filters supposed to be implemented.
I am trying to pass the filters in the below manner:
/wc-api/v3/products?filter[category]=accessories&filter[brand]=KOOVS - This doesn't seem to be working, getting the same result set regardless of what filters I set. Only category filter works.
Upvotes: 3
Views: 1868
Reputation: 1
Should be like this
accessories&filter[brand]="KOOVS"
not
accessories&filter[brand]=KOOVS
since its a string
Upvotes: 0