docs: def _adapt_response(self, response):
          """Convert error responses to standardized ErrorDetails."""
          if response.headers['content-type'] == 'application/json':
              body = response.json()
              status = response.status_code
  
              if body.get('errors'):
                  return self._complex_response_to_error_adapter(body)
  
              elif body.get('code') and body.get('message'):
                  return self._simple_response_to_error_adapter(status, body)
  
              elif body.get('error'):
                  code = response.reason
                  return self._message_to_error_adapter(status, code, body)
  
          raise UnknownHttpError(response)