-
Notifications
You must be signed in to change notification settings - Fork 219
Store API: allow searching by slug
and include slug
in the response
#9017
Conversation
The release ZIP for this PR is accessible via:
Script Dependencies ReportThere is no changed script dependency between this branch and trunk. This comment was automatically generated by the TypeScript Errors Report
🎉 🎉 This PR does not introduce new TS errors. |
Size Change: 0 B Total Size: 1.1 MB ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I left a small comment inline. Other than that, I wonder if we anything like this for SKUs? If not, that would be a good addition as well perhaps in a separate PR.
Other than that, I've tested the PR and it works as advertise. Good job!
Thanks for the review! 🙌 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Good job!
Yay! I had a branch fixing this that I never got it to PR. Thank you for fixing it :D |
This PR adds multiple improvements to the Store API:
/wc/store/v1/products/:slug
slug
from/wc/store/v1/products
and/wc/store/v1/products/:id
/wc/store/v1/products?slug=first-slug,second-slug
Fixes #8985
Testing
Automated Tests
User Facing Testing
/wc/store/v1/products
and check the returned json includes the productslug
./wc/store/v1/products/:id
(where:id
is the ID of a product in your site) and check the returned json includes the productslug
./wc/store/v1/products/:slug
(where:slug
is the slug of a product in your site) and check the product is returned and the returned json includes the productslug
.WooCommerce Visibility
Changelog