BerriAI/litellm · error · ValueError
secret {secret_name} not found in Google Secret Manager
Error message
secret {secret_name} not found in Google Secret Manager What it means
Follow-on guard after a successful Google Secret Manager response: the secret payload is absent from the response JSON (no 'payload.data' field), so the named secret exists but has no value to decode.
Source
Thrown at litellm/secret_managers/google_secret_manager.py:98
raise ValueError(f"secret {secret_name} not found in Google Secret Manager. Error: {response.text}")
verbose_logger.debug(
"Google Secret Manager retrieval response status code: %s",
response.status_code,
)
# Parse the JSON response and return the secret value
secret_data: Final = response.json()
_base64_encoded_value: Final = secret_data.get("payload", {}).get("data")
# decode the base64 encoded value
if _base64_encoded_value is not None:
_decoded_value: Final = base64.b64decode(_base64_encoded_value).decode("utf-8")
self.cache.set_cache(secret_name, _decoded_value) # Cache the retrieved secret
return _decoded_value
self.cache.set_cache(secret_name, None) # Cache that the secret was not found
raise ValueError(f"secret {secret_name} not found in Google Secret Manager")
View on GitHub (pinned to 77b7c6c40c)
Solutions
- Create the secret {secret_name} in Google Secret Manager or fix the name being requested.
- Verify the project id and IAM permissions for the accessor identity.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at litellm/secret_managers/google_secret_manager.py:98 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/31ed28b44cbec1c9.
Report an issue: GitHub.