Open-source Python library for AI browser agents, plus Browser Use Cloud: stealth browsers and a hosted agent API.
Python ai-agentsai-toolsbrowser-agentbrowser-automationbrowser-usecdpcloud-browsercomputer-useheadless-browserllmmcpplaywrightpythonremote-browserstealth-browserweb-automationweb-scraping
Api key rename
Magnus Müller16d8833048b0
diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yamlindex f32e0cf52..50c7e1605 100644--- a/.github/workflows/test.yaml+++ b/.github/workflows/test.yaml@@ -91,7 +91,7 @@ jobs:ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}GOOGLE_API_KEY: ${{ secrets.GOOGLE_API_KEY }}GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}- AZURE_OPENAI_API_KEY: ${{ secrets.AZURE_OPENAI_API_KEY }}+ AZURE_OPENAI_KEY: ${{ secrets.AZURE_OPENAI_KEY }}AZURE_OPENAI_ENDPOINT: ${{ secrets.AZURE_OPENAI_ENDPOINT }}strategy:matrix:diff --git a/browser_use/llm/azure/chat.py b/browser_use/llm/azure/chat.pyindex 0a20e3552..ec83473a7 100644--- a/browser_use/llm/azure/chat.py+++ b/browser_use/llm/azure/chat.py@@ -43,7 +43,7 @@ class ChatAzureOpenAI(ChatOpenAILike):def _get_client_params(self) -> dict[str, Any]:_client_params: dict[str, Any] = {}- self.api_key = self.api_key or os.getenv('AZURE_OPENAI_API_KEY')+ self.api_key = self.api_key or os.getenv('AZURE_OPENAI_KEY') or os.getenv('AZURE_OPENAI_API_KEY')self.azure_endpoint = self.azure_endpoint or os.getenv('AZURE_OPENAI_ENDPOINT')self.azure_deployment = self.azure_deployment or os.getenv('AZURE_OPENAI_DEPLOYMENT')params_mapping = {diff --git a/tests/ci/models/test_llm_azure.py b/tests/ci/models/test_llm_azure.pyindex 1c7ed6996..a90ff89ba 100644--- a/tests/ci/models/test_llm_azure.py+++ b/tests/ci/models/test_llm_azure.py@@ -9,7 +9,7 @@ async def test_azure_gpt_4_1_mini(httpserver):await run_model_button_click_test(model_class=ChatAzureOpenAI,model_name='gpt-4.1-mini',- api_key_env='AZURE_OPENAI_API_KEY',+ api_key_env='AZURE_OPENAI_KEY',extra_kwargs={}, # Azure endpoint will be added by helperhttpserver=httpserver,)