BerriAI/litellm · error · ValueError
Unsupported storage backend type: {backend_type}. Supported
Error message
Unsupported storage backend type: {backend_type}. Supported types: azure_storage What it means
Raised by the storage backend factory when the requested backend_type string is anything other than 'azure_storage'. The factory is intentionally minimal: it maps 'azure_storage' -> AzureBlobStorageBackend() and rejects everything else, so any typo or unsupported backend name (s3, gcs, local) fails immediately.
Source
Thrown at litellm/llms/base_llm/files/storage_backend_factory.py:37
Backends are configured using the same environment variables as their
corresponding callbacks. For example, "azure_storage" uses the same
env vars as AzureBlobStorageLogger.
Args:
backend_type: Backend type identifier (e.g., "azure_storage")
Returns:
BaseFileStorageBackend: Instance of the appropriate storage backend
Raises:
ValueError: If backend_type is not supported
"""
verbose_logger.debug("Creating storage backend: type=%s", backend_type)
if backend_type == "azure_storage":
return AzureBlobStorageBackend()
else:
raise ValueError(f"Unsupported storage backend type: {backend_type}. Supported types: azure_storage")
View on GitHub (pinned to 6c2dcb801b)
Solutions
- Set backend_type exactly to 'azure_storage'.
- Check your litellm version (pip show litellm) — if you need another backend, upgrade to a version whose factory supports it.
- For non-Azure storage, upload files via a pre-signed URL flow or your own storage layer instead of this factory.
- If adding a custom backend, register it in the factory (add an elif branch returning your BaseFileStorageBackend subclass).
Example fix
# before backend = create_storage_backend(backend_type='s3') # ValueError # after backend = create_storage_backend(backend_type='azure_storage')
Defensive patterns
Strategy: validation
Validate before calling
SUPPORTED_BACKENDS = {'azure_storage'}
if backend_type not in SUPPORTED_BACKENDS:
raise ConfigError(f'{backend_type!r} unsupported; choose from {SUPPORTED_BACKENDS}') Type guard
def is_supported_backend(value: str) -> bool:
"""Type guard for storage backend factory inputs."""
return value in {'azure_storage'} Prevention
- Pin the litellm version your config was written for and check its factory source for supported types.
- Fail fast on unknown config keys at app boot rather than at first file operation.
- Watch release notes when new backends are added before adopting them.
When it happens
Trigger: Passing backend_type='s3', 'S3', 'azure-blob', 'Azure_Storage' or any other string to the factory (via proxy file-management config or direct call); version drift where config written for a newer litellm mentions backends this version does not ship.
Common situations: Config copied from docs of a different litellm version; assuming S3/GCS support exists because constants exist elsewhere; case-sensitive string mismatches between config value and factory check.
Related errors
- Error: {response.status_code} - {response.text}
- Missing Authorization header
- Invalid bearer token
- Invalid API key
- Prompt '{prompt_id}' not found
AI-assisted analysis of BerriAI/litellm@6c2dcb801b (2026-08-15).
Data as JSON: /api/errors/eb43df68f44a580c.
Report an issue: GitHub.