Shopify API Versions Introduced. API endpoints not working now.
mustafaredsignal opened this issue · comments
Hi Guys,
Your API has stopped working now as Shopify have introduced API version system. For reference please check their article and fix this ASAP.
https://developers.shopify.com/changelog/introducing-admin-api-versioning-and-developer-preview
- GET /admin/api/2019-04/products.json
Retrieves a list of products - GET /admin/api/2019-04/products/count.json
Retrieves a count of products - GET /admin/api/2019-04/products/#{product_id}.json
Retrieves a single product - POST /admin/api/2019-04/products.json
Creates a new product
Waiting for your action on it.
Thanks
Hi !
I'm going to look at this, but I'm pretty sure Shopify has not break all the old URL like that. Shopify is not known to break 100% of code like this.
Hi @bakura10
Thanks for your attention onto it. Somehow their changes has affect on our app now. Since two days this is not working properly until we checked and found it. In your Shopify-v1.php here is need to add Version number which I think you can add in a way devs could specify version api/{year-month} during client initialization level.
Thanks
Hi,
I need to check carefully how to implement that (although I think a simple parameter may work indeed). However as said, if Shopify has suddenly break all previous URL, this is really really bad. I've checked on our apps and we didn't encounter any issue for now.
What kind of errors exactly do you receive now?
I've read carefully the doc and if you don't specify a version (current behavior) then you are on the latest version (the current one). So if something breaks on your end right now, it's likely unrelated to that as calling versionless URL and versioned URL will lead to the same result.
However I'm working on it and should have a new version with versioning support soon.
Hi !
I've just released the v5 of this library. It now requires you to pass a version when creating a client. If you are using the built-in factory, you can include the version below the zfr_shopify top-key.
I'm closing this, but if you are encountering any issue, please let me know by opening a new issue.