Closed hicreate closed 3 years ago
Looks like you are using one of the legacy API, however, in recent APIs we do support fetching only limited coupons by using code
or search
query param. You can using like so: wp-json/wc/v3/coupons?search=foo
.
I am closing the issue, but if you are already using the new API, then please comment back with following details so that we can debug further:
If I retrieve a coupon using /coupons?code=sometexthere the get request ignores the query params and just returns all coupons - is this intended and if not can we implement search by query params so that I can pass a code to the end point and retrieve just the coupon associated?