w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
How do I manage updates to resources when users are using the same major (but different minor) versions of my RESTful API?

If you are trying for a backward compatible server, then I would make the server only remove values when passed a field value that is explicitly null, e.g.

{
  "title":"Fahrenheit 451",
  "author":"Ray Bradbury",
  "publisher":"Penguin",
  "edition": null
}

That way clients coded against the v1.1 API have the ability to explicitly remove that field value, but those targeting v1.0 do not accidentally make changes.





© Copyright 2018 w3hello.com Publishing Limited. All rights reserved.