Hi,
I posted my approach for server implementation best practice http://restafar.com/create-new-rest-server/.
to summarize:
- Use flat model and not complex paths, for example instead of /account/househols/user you can assume that user is always belongs to household that always belongs to account, so you can simply use /user.
- HTTP methods - don't use custom methods, just add the action you want to the path, it's more clear and works better with firewalls, for example, instead of PUT /user, you can use POST /user/add.
- Use HTTP error codes only for HTTP errors and return your applicative errors in the response, it will enable partial errors and warnings.
Will be glad for comments on my post.
Server implementation best practice
Moderators: StaffingSupport, s.emmons, BullhornSupport