BerriAI/litellm · error · ScalewayAudioTranscriptionException
Scaleway API key not found. Pass `api_key=...` or set the SC
Error message
Scaleway API key not found. Pass `api_key=...` or set the SCW_SECRET_KEY environment variable.
What it means
Scaleway audio transcription credential guard: no API key was passed via api_key and the SCW_SECRET_KEY environment variable is unset/empty, so ScalewayAudioTranscriptionException is raised before any request is sent.
Source
Thrown at litellm/llms/scaleway/audio_transcription/transformation.py:85
status_code=status_code,
headers=headers,
)
def validate_environment(
self,
headers: dict,
model: str,
messages: list[AllMessageValues],
optional_params: dict,
litellm_params: dict,
api_key: str | None = None,
api_base: str | None = None,
) -> dict:
if api_key is None:
api_key = get_secret_str("SCW_SECRET_KEY")
if not api_key:
raise ScalewayAudioTranscriptionException(
message=(
"Scaleway API key not found. Pass `api_key=...` or set the SCW_SECRET_KEY environment variable."
),
status_code=401,
headers={},
)
default_headers: Final = {
"Authorization": f"Bearer {api_key}",
"accept": "application/json",
}
default_headers.update(headers or {})
return default_headers
def transform_audio_transcription_request(
self,
model: str,
audio_file: FileTypes,View on GitHub (pinned to 77b7c6c40c)
Solutions
- Set the SCW_SECRET_KEY environment variable.
- Or pass api_key=... to the transcription call.
Example fix
litellm.transcription(model="scaleway/...", api_key="<scw-secret>", file=...)
Defensive patterns
Strategy: validation
When it happens
Trigger: Triggered when calling Scaleway audio transcription without an API key: api_key not passed and SCW_SECRET_KEY unset.
Common situations: See trigger scenarios.
AI-assisted analysis of BerriAI/litellm@77b7c6c40c (2026-08-18).
Data as JSON: /api/errors/ef7d63c2cf1a1098.
Report an issue: GitHub.