The actual content of the error should not be the last - if you do not control individual operations in the service (i.e. if POST with some data to a specific URL returns a specific answer) - realistic, then you just look at the status code; and for that you want to look at all the HTTP Status Codes and look at those that look like errors as far as you know.
As a good starting point, you can consider almost all 5xx codes; since they are all related to server errors.
You may also consider some of the 4xx codes (although they are usually associated with clients, so be ruthless). In particular:
400 - Bad Request - while you can be sure that the server must understand the request
404 - Not Found - if you are sure that this URL should be present
405 - Method Not Allowed - if you are sure that this HTTP verb should be supported (for example, POST or DELETE)
For some of the narrower 4xx codes, for example. 413 Request Entity Too Large or 414 Request-URI Too Long ; they could happen after several days or months of normal operation due to things like security updates. In this case, you do not necessarily determine that the service is disabled as such, but you can expect that it will not be able to fulfill the intended function.
source share