What should I return for an HTTP PUT REST call that results in no changes?

Viewed 2319

I have a resource that is created by POST, then can be updated via PUT.

If someone calls PUT and doesn't change anything, should it still return a 200 and look like the update has been performed (even though nothing was actually updated)?

1 Answers

In my opinion, 200 is fine. The request was OK and was processed the way it should. There is no semantic status code expressing an operation that did not result in any changes.

Related