thanks for reading and attentions.
My question is, exist or can I follow a table of HTTP codes to handle my error using REST Webservices ? Let me explain better:
UserRestWS (example)
"/users" GET , if error or not return 200, because return the empty or not empty list of users);
"/{code}/user" GET, if find user return 200 with user as entity, otherwise 404 with custom error message.
"/user/new" POST, if save operation ends successfully I return 200, otherwise for validation errors (some fields are wrong) ? Server problem or computation error ?
"/{code}/update" PUT, same of above
- "/{code}/delete" DELETE, same of above
I would follow a "standard" usage like HTTP codes, or other standard technique. Can you suggest me a table for this kind of problem ?
For me, it always is an 500 error code.
I googled and I find these links, not helpful for me. https://en.wikipedia.org/wiki/List_of_HTTP_status_codes#5xx_Server_Error http://www.restapitutorial.com/httpstatuscodes.html
