mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-26 11:14:04 +00:00
(feat) proxy: config - azure allow users to pass in base_url
This commit is contained in:
parent
558e1f7904
commit
9ac8d403d6
1 changed files with 2 additions and 0 deletions
|
@ -842,6 +842,8 @@ class Router:
|
|||
api_key = os.getenv(api_key_env_name)
|
||||
|
||||
api_base = litellm_params.get("api_base")
|
||||
base_url = litellm_params.get("base_url")
|
||||
api_base = api_base or base_url # allow users to pass in `api_base` or `base_url` for azure
|
||||
if api_base and api_base.startswith("os.environ/"):
|
||||
api_base_env_name = api_base.replace("os.environ/", "")
|
||||
api_base = os.getenv(api_base_env_name)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue