The server detected an infinite loop while processing the request.
508 Loop Detected is another WebDAV code. The server detected that processing the request would create an infinite loop (e.g. circular symlinks, recursive PROPFIND on cyclic resource graph). Outside WebDAV, 508 is occasionally used by APIs to signal recursion-depth-exceeded errors.
When servers should return it: Return 508 when a request would cause infinite recursion or self-reference.
HTTP/2 508
content-type: application/json
{"error":"loop detected","depth":1024}
For a one-page reference of all HTTP status codes, see the HTTP cheat sheet. For testing API responses, try the API Tester tool. For inspecting responses on the command line, the curl cheat sheet covers the most common flags.