need two services related to the object "item".
To get the details of the item. Though it is a method to get data, I will be using POST since my pathParam/MatrixParam list is too long(Say, purchaserIds provided in the matrixParam is used to fetch the items they have bought). To avoid "URI too long" exception, I made it POST.
To save the item with some details. This will also be a POST method since it is saving/updating.
Now, both services will have the same url http://...../item and both will have httpMethod as POST.
How can we differentiate these 2 services by the URL? Is it right to make it "http://.../item/save" and ".../item/get"?
If your URLs would end up too long, it sounds like your URL design is wrong - GET against
http://.../items/1/purchasers/
would (for example) be a decent URL to return all the people who have bought item 1, then to update item 1, you would PUT tohttp://.../items/1/
and to create an item you would POST tohttp://.../items/
The URL scheme you decide does not sound RESTful, as you're using it to describe actions rather than resources - the URL should identify the resource you are accessing rather than what to do to it.