Reputation: 27011
In my RESTful Web API application, I am using the below templates at the moment:
Get one product by id:
GET api/product/12
Save product
POST api/product
Update product
PUT api/product
What is the best uri template for bulk post?
My inital thought is this:
POST api/product/bulk
Upvotes: 0
Views: 120
Reputation: 279
[WebInvoke(Method = "POST",BodyStyle = WebMessageBodyStyle.Wrapped,
ResponseFormat = WebMessageFormat.Json,
RequestFormat = WebMessageFormat.Json)]
void SaveProduct(int productId);
suppose that, you have the following service with proper implementation. for this, your service uri will be :
yourDomain/SaveProduct/productId=productIdNumber
Upvotes: 3