BerriAI/litellm · error · GuardrailRaisedException
Singulr API returned HTTP {exc.response.status_code}: {exc.r
Error message
Singulr API returned HTTP {exc.response.status_code}: {exc.response.text} What it means
Error "Singulr API returned HTTP {exc.response.status_code}: {exc.response.text}" thrown in BerriAI/litellm.
Source
Thrown at litellm/proxy/guardrails/guardrail_hooks/singulr/singulr.py:164
response: Final = await self.async_handler.post(
url=endpoint,
headers=self._build_headers(),
json=payload,
timeout=self.timeout,
)
response.raise_for_status()
result: Final = SingulrGuardrailResponse.model_validate(response.json())
verbose_proxy_logger.debug("Singulr: result=%s", result)
return result
except httpx.HTTPStatusError as exc:
verbose_proxy_logger.error(
"Singulr API returned HTTP %s: %s",
exc.response.status_code,
str(exc),
)
if self.block_on_error:
raise GuardrailRaisedException(
guardrail_name=self.guardrail_name,
message=(f"Singulr API returned HTTP {exc.response.status_code}: {exc.response.text}"),
) from exc
return None
except httpx.TransportError as exc:
verbose_proxy_logger.error("Singulr API unreachable: %s", str(exc))
if self.block_on_error:
raise GuardrailRaisedException(
guardrail_name=self.guardrail_name,
message=f"Singulr API unreachable (block_on_error=True): {exc}",
) from exc
return None
except (ValueError, pydantic.ValidationError) as exc:
verbose_proxy_logger.error("Singulr API returned an invalid response: %s", str(exc))
if self.block_on_error:
raise GuardrailRaisedException(View on GitHub (pinned to 77b7c6c40c)
Solutions
- Check the HTTP status and response body in the error for the API-side cause.
- Verify the Singulr API key and request payload are valid.
When it happens
Trigger: Thrown at litellm/proxy/guardrails/guardrail_hooks/singulr/singulr.py:164 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of BerriAI/litellm@77b7c6c40c (2026-08-18).
Data as JSON: /api/errors/38090d9fe92607d8.
Report an issue: GitHub.