refactor(proxy): tighten pass-through credential type annotations

This commit is contained in:
mateo-berri 2026-08-04 23:12:31 -07:00
parent 1fefd80925
commit 5d7bfbc950
2 changed files with 3 additions and 3 deletions

View file

@ -22,7 +22,7 @@ def _get_proxy_llm_router() -> "Router | None":
return llm_router
def _get_str_value(values: dict | None, key: str) -> str | None:
def _get_str_value(values: dict[str, object] | None, key: str) -> str | None:
value: Final = values.get(key) if values is not None else None
return value if isinstance(value, str) else None

View file

@ -382,8 +382,8 @@ class LiteLLMParamsTypedDict(TypedDict, total=False):
## RESPONSES API → CHAT COMPLETIONS BRIDGE ##
use_chat_completions_api: Optional[bool]
## PASS-THROUGH ENDPOINTS ##
use_in_pass_through: Optional[bool]
litellm_credential_name: Optional[str]
use_in_pass_through: bool | None
litellm_credential_name: str | None
## UNIFIED PROJECT/REGION ##
region_name: Optional[str]
## VERTEX AI ##