From 68ae8887303aa77fe3c3f0ac33e42c4ce5d75de2 Mon Sep 17 00:00:00 2001 From: Ishaan Jaff Date: Fri, 14 Feb 2025 21:32:37 -0800 Subject: [PATCH] fix test --- litellm/types/router.py | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/litellm/types/router.py b/litellm/types/router.py index 0423011cd58..b6049657bfc 100644 --- a/litellm/types/router.py +++ b/litellm/types/router.py @@ -8,10 +8,13 @@ import uuid from typing import Any, Dict, List, Literal, Optional, Tuple, Union, get_type_hints import httpx +from httpx import AsyncClient, Client from openai import AsyncAzureOpenAI, AsyncOpenAI, AzureOpenAI, OpenAI from pydantic import BaseModel, ConfigDict, Field from typing_extensions import Required, TypedDict +from litellm.llms.custom_httpx.http_handler import AsyncHTTPHandler, HTTPHandler + from ..exceptions import RateLimitError from .completion import CompletionRequest from .embedding import EmbeddingRequest @@ -154,7 +157,18 @@ class GenericLiteLLMParams(BaseModel): configurable_clientside_auth_params: CONFIGURABLE_CLIENTSIDE_AUTH_PARAMS = None # for passing in custom OpenAI / Azure OpenAI clients - client: Optional[Union[OpenAI, AsyncOpenAI, AzureOpenAI, AsyncAzureOpenAI]] = None + client: Optional[ + Union[ + OpenAI, + AsyncOpenAI, + AzureOpenAI, + AsyncAzureOpenAI, + AsyncClient, + Client, + AsyncHTTPHandler, + HTTPHandler, + ] + ] = None ## LOGGING PARAMS ## litellm_trace_id: Optional[str] = None ## UNIFIED PROJECT/REGION ##