1

This request is for an auto parts store. The products are filtered by car make, model, year, etc. When a client apply a filter I need to make an API call to manufacturer server, get products and display those products and the client must be able to purchase those products.

Is there any module for this? I do not know where to begin with this.

  • you can use catalogProductRepositoryV1 with search criteria – Aditya Shah Oct 25 '18 at 9:29
  • Thanks Aditya. I am new to magento. Can you give me little more details? – Leonida-Alexandru Diaconu Oct 25 '18 at 10:11
  • Okay, do know how to call APIs ? – Aditya Shah Oct 25 '18 at 10:12
  • I do nkow how to call APIs but i am not familiar with magento's API. Also the remote database it is not the same structure. – Leonida-Alexandru Diaconu Oct 25 '18 at 14:22
  • ohk then i am adding an answer, let me know if any query – Aditya Shah Oct 25 '18 at 15:47
0

Search criteria will be helpful

searchCriteria[filter_groups][<index>][filters][<index>][field]=<field_name>
searchCriteria[filter_groups][<index>][filters][<index>][value]=<search_value>
searchCriteria[filter_groups][<index>][filters][<index>][condition_type]=<operator>

where

  • field is an attribute name.
  • value specifies the value to search for.
  • condition_type specifies condition[ex: eq , finset, like, from, to]

for your case

http://magento/index.php/rest/V1/products?
searchCriteria[filter_groups][0][filters][0][field]=category_id&
searchCriteria[filter_groups][0][filters][0][value]=78&
searchCriteria[filter_groups][0][filters][0][condition_type]=eq

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.