What is the best way to design the API's which supports multiple versions. How do I ensure that even if the schema of my data changes(minor changes), the consumers of my api's are not affected? Any reference architecture, guidelines is really helpful.
For simple APIs you can maintain different versions by defining a Constant in your app. This constant will be the path to the root of your API endpoint. Typically this would carry the same name as your app's version, like "myApp/v1-8-5/" assuming your app version was 1.8.
Mark Nottingham has a good blog post on how to version Web (REST) APIs
http://www.mnot.net/blog/2011/10/25/web_api_versioning_smackdown
Also about API versioning in general:
http://theamiableapi.com/2011/10/18/api-design-best-practice-plan-for-evolution/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With