Hi,
I wish to build up a website that follows the RESTful architecture. In my site, each user is identified by a permanent username and may manage their own settings. For the settings resource, I'm torn between two URI designs.
Option 1: /users/{username}/settings
Here is a generic settings resource URL pattern. Only the logged in user can do a GET/PUT to his/her specific settings resource. It's quite complicated though, as other user specific resources need to follow this lead. It makes admin authentications which have access to all the settings of all users (or at least part of it) simpler.
Option 2: /my/settings
The URL for the settings resource of the currently logged in user. It's much simpler programming, but the URL doesn't really specify which resource it really is. The '/my' part becomes sort of an alias to '/users/{username}'.
Almost all websites follow a similar approach as option 2. What do you guys think?