commit | 8f42f87b21768b6b23c1353e234788118c4fed10 | [log] [tgz] |
---|---|---|
author | Shawn O. Pearce <sop@google.com> | Tue Nov 27 13:04:21 2012 -0800 |
committer | Shawn O. Pearce <sop@google.com> | Tue Nov 27 13:05:33 2012 -0800 |
tree | 74b2c2347f6a047dceccfed694e9fda7b8080160 | |
parent | 06bfb9030aca528e19457fa00bede4dc2386ff33 [diff] |
Use HTTP 201, 204 response codes in REST API When creating a new entity on the server respond HTTP 201 Created with the JSON representation of the entity in the body. When deleting an existing entity, respond with HTTP 204 No Content, telling the client there is no more content behind the resources that was just deleted. This is a hint that a future GET is likely to return 404 Not Found. Change-Id: Ia7b3964267fcd55b4abcc49dcd6ba4c61f61fd5d