cancel
Showing results for 
Search instead for 
Did you mean: 

Custom API Magento versioning

Custom API Magento versioning

Hello! I am working on three different platforms (android, ios, web) that will use Magento API and some of my extended magento custom APIs. I want to be able to set minimum client versions per platform on the config.xml and return an error that will tell the user to update their application if their request contains a client version that is less than the set minimum version on the config of Magento.

 

I've started on this but I fail to find the file where all requests will go first and be able to identify if the client's request satisfies the requirements of the config. It seems like, I will have to go through each module and on all the verb functions (_retrieve, _create, etc...) and add there the conditions.

 

How should I go about this? Is there a file where all requests go first so I can filter there and won't need to have duplicate codes? Is there a better way to achieve the versioning I want?

 

Thank you.