diff --git a/docs/my-website/docs/proxy/configs.md b/docs/my-website/docs/proxy/configs.md index a50b3f6460..f117bf49f7 100644 --- a/docs/my-website/docs/proxy/configs.md +++ b/docs/my-website/docs/proxy/configs.md @@ -409,12 +409,12 @@ You can view your cost once you set up [Virtual keys](https://docs.litellm.ai/do ## Load API Keys -### Load API Keys from Environment +### Load API Keys / config values from Environment -If you have secrets saved in your environment, and don't want to expose them in the config.yaml, here's how to load model-specific keys from the environment. +If you have secrets saved in your environment, and don't want to expose them in the config.yaml, here's how to load model-specific keys from the environment. **This works for ANY value on the config.yaml** -```python -os.environ["AZURE_NORTH_AMERICA_API_KEY"] = "your-azure-api-key" +```yaml +os.environ/ # runs os.getenv("YOUR-ENV-VAR") ``` ```yaml @@ -424,7 +424,7 @@ model_list: model: azure/chatgpt-v-2 api_base: https://openai-gpt-4-test-v-1.openai.azure.com/ api_version: "2023-05-15" - api_key: os.environ/AZURE_NORTH_AMERICA_API_KEY + api_key: os.environ/AZURE_NORTH_AMERICA_API_KEY # 👈 KEY CHANGE ``` [**See Code**](https://github.com/BerriAI/litellm/blob/c12d6c3fe80e1b5e704d9846b246c059defadce7/litellm/utils.py#L2366)