3 ms·
Just put a version number in the API root -- it really doesn't matter where. http://api.mysite.com/1/ http://api.mysite.com/1/ , http://api.mysite.com/?version=
by jmillikin 16y ago
Just put a version number in the API root -- it really doesn't matter where. http://api.mysite.com/1/ http://api.mysite.com/1/ , http://api.mysite.com/?version=1 http://api.mysite.com/?version=1 , etc, anything will work. In fact, you can support multiple styles easily.
Since it's REST, clients shouldn't be hardcoding any URLs aside from the API root. Therefore, if you think a version is ugly, you can make the sub-URLs unversioned for now and version them later if needed.
- deleted 16y ago[deleted]