BerriAI/litellm · error · HTTPException
Polling response {response_id} not found or expired
Error message
Polling response {response_id} not found or expired What it means
Polling lookup on response retrieval: Redis is configured, but ResponsePollingHandler.get_state returned nothing for the polling response_id — the polling entry expired from the cache or never existed; surfaced as 404.
Source
Thrown at litellm/proxy/response_api_endpoints/endpoints.py:723
)
from litellm.proxy.response_polling.polling_handler import ResponsePollingHandler
# Check if this is a polling ID
if ResponsePollingHandler.is_polling_id(response_id):
# Handle polling response
if not redis_usage_cache:
raise HTTPException(
status_code=500,
detail="Redis cache not configured. Polling requires Redis.",
)
polling_handler: Final = ResponsePollingHandler(redis_cache=redis_usage_cache)
# Get current state from cache
state: Final = await polling_handler.get_state(response_id)
if not state:
raise HTTPException(
status_code=404,
detail=f"Polling response {response_id} not found or expired",
)
# Return the whole state directly (OpenAI Response object format)
# https://platform.openai.com/docs/api-reference/responses/object
return state
# Normal provider response flow
data: Final = await _read_request_body(request=request)
data["response_id"] = response_id
processor: Final = ProxyBaseLLMRequestProcessing(data=data)
try:
return await processor.base_process_llm_request(
request=request,
fastapi_response=fastapi_response,
user_api_key_dict=user_api_key_dict,
route_type="aget_responses",View on GitHub (pinned to 77b7c6c40c)
Solutions
- Poll before the response TTL expires; re-submit the request if the stored response expired.
- Verify the response_id matches the one returned at submission.
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at litellm/proxy/response_api_endpoints/endpoints.py:723 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/ac92016eb3299b4b.
Report an issue: GitHub.