MCPcopy Create free account
hub / github.com/TheSmallHanCat/flow2api / _build_gemini_error_payload

Function _build_gemini_error_payload

src/api/routes.py:535–542  ·  view source on GitHub ↗
(status_code: int, message: str)

Source from the content-addressed store, hash-verified

533
534
535def _build_gemini_error_payload(status_code: int, message: str) -> Dict[str, Any]:
536 return {
537 "error": {
538 "code": status_code,
539 "message": message,
540 "status": GEMINI_STATUS_MAP.get(status_code, "UNKNOWN"),
541 }
542 }
543
544
545def _build_gemini_error_response_from_handler(payload: Dict[str, Any]) -> JSONResponse:

Callers 5

_iterate_gemini_streamFunction · 0.85
get_gemini_modelFunction · 0.85
generate_contentFunction · 0.85
stream_generate_contentFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected