Jump to content

[8.1.0] Webservice filters on't seem to work?


SparkyRih

Recommended Posts

I have written a .NET application which communicates with my PrestaShop webshop. I developed this application for 1.5.x a long time ago.

Now I started working on a new version for 8.0.1, but due to lack of time didn't finish it.

I recently upgrade my webshop to 8.1.0, and started working on the .NET application again, but the filters don't seem to work anymore... I did not make any changes in my application, just fired it up...

 

This is an example of a URL which is used to obtain the products for a specific category:

`https://<url>/api/products?filter[id_category_default]=[10]filter[available_for_order]=[1]filter[active]=[1]filter[online_only]=[0]&display=full`

It just returns all my products (also the inactive ones). When I remove the `&display=full` parameter, it just returns nothing.

 

Even this one, just returns all categories, instead of just (in my case) 3 main categories:

`https://<url>/api/categories/filter[id_parent]=[2]&display=full`

 

Is this a bug, or has something changed in the API (I cannot find Qanything about that in the documentation).

Link to comment
Share on other sites

  • 11 months later...
  • 1 month later...

I stopped working on this project for a while, just kept my old PrestaShop online, and kept updating the products there to keep my store terminal working. But I just picked up this project again. Apparently I did fix it, however, the URL which is constructed is still the same as in my original post... However, I did get stuck on the next one back than... I doubt this is the same issue since I would've fixed it already...

This is the endpoint which gets me stuck now:

https://<url>/api/product_option_values?filter[id_product]=[21]filter[id_product_attribute]=[43]&display=full

Edit: It's probably becasue those parameters don't exist on that route :) How did I ever try that?

Edited by SparkyRih (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...