If you are a web developer you will obviously know that we have some fancy http verbs hanging around in the specification like GET or POST. PUT is a verb that although seldom used, provides a very distinct way of manipulating the URI. Getting down to the semantics, here's the definition of PUT:
The PUT method requests that the enclosed entity be stored under the supplied Request-URI. If the Request-URI refers to an already existing resource, the enclosed entity SHOULD be considered as a modified version of the one residing on the origin server. If the Request-URI does not point to an existing resource, and that URI is capable of being defined as a new resource by the requesting user agent, the origin server can create the resource with that URI.
So basically a PUT allows us to create or update a specific URI. PUT isn't really utilized in the standard browser web process for some reason, but it has had a resurgence since the Restful movement began. Here is where the nerd fight begins (i'm guilty of having it as well).
POST has been the defacto method for creating since the beginning of time. Maybe not that far back, but as far as this developer remembers on the web. So naturally people kind of default to this method as for creating things. This is great and it should be this way because reading the definition, this is the verb for creating:
The POST method is used to request that the origin server accept the entity enclosed in the request as a new subordinate of the resource identified by the Request-URI in the Request-Line. POST is designed to allow a uniform method to cover the following functions:
It then goes on to describe common functions like posting article to group, appending to a database, sending data for processing, and the final one is this "Annotation of existing resources;" And this is what I believe to be the one vague bullet point that bring up the fight of POST vs PUT.
So how do we look at it? Technically it's adding to whatever URI you've given it. Some take that to mean it functions exactly like a PUT. I believe it doesn't. Simplifying the verb a bit, we can understand that POST is append and PUT is replace. The key point here is the PUT action is replacing the entire contents of the URI. On the other hand, the POST action is adding to the contents that are already available at the URI.
Lets dive into a simple example of a restful api around file structures:
== POST ==
GET URI: /api/folder/
Folder
-> dir1
-> dir2
-> text.xt
POST madzak.txt=text to URI: /api/folder/
GET URI: /api/folder/
Folder
-> dir1
-> dir2
-> text.txt
-> madzak.txt
POST madzak.txt=text2 to URI: /api/folder/
GET URI: /api/folder/
Folder
-> dir1
-> dir2
-> text.txt
-> madzak.txt (text)
-> madzak.txt (text2)
== PUT ==
GET URI: /api/folder/
Folder
-> dir1
-> dir2
-> text.xt
PUT madzak.txt=text to URI: /api/folder/
GET URI: /api/folder/
Folder
-> madzak.txt (text)
PUT madzak.txt=text2 to URI: /api/folder/madzak.txt
GET URI: /api/folder/
Folder
-> madzak.txt (text2)
This is how I (and i believe other purists) interrupt the implementations of the spec to behave. Notice how in the PUT if I used the same URI as the POST I removed that whole directory structure. This is because it's a replace not an append. Should you want to add the madzak.txt file to the existing structure you'd naturally use a POST because it appends. You could however use a PUT by changing the URI to be /api/folder/madzak.txt, which you see I did in the update PUT request. This says Create or Replace what's at this current URI. Given that madzak.txt doesn't exist, the implementation could create madzak.txt within that folder.
I'll leave you with my final comments on this topic. Just because the industry follow a certain way, doesn't make it correct. If you want to claim you are truly a restful interface, the spec says you should behave this way. If you don't want to follow the spec then make it abundantly clear in the documentation you using different behavior. Although i find it a bit foolish to write more documentation when you could just follow spec and point to what is already written.
HTTP Spec: http://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html