> For the complete documentation index, see llms.txt.
Skip to main content

Check out Port for yourself ➜ 

Azure OpenAI setup

Connect Port to OpenAI models hosted in your Azure OpenAI deployment. This guide walks you through storing your Azure OpenAI credentials and registering Azure OpenAI as an LLM provider in Port.

Prerequisites

  • An active Azure subscription with Azure OpenAI Service enabled.
  • An Azure OpenAI deployment with the models you want to use. You can create deployments in the Azure OpenAI Studio.
  • Your Azure OpenAI API key and endpoint URL.

Step 1: Gather your Azure OpenAI configuration

Before configuring the provider, collect the following information from your Azure OpenAI deployment:

  • Endpoint URL: Your Azure OpenAI endpoint (e.g., https://your-resource-name.openai.azure.com).
  • API Key: Your Azure OpenAI API key. You can find this in the Azure portal under your Azure OpenAI resource's Keys and Endpoint section.
  • Deployment name: The name of your model deployment in Azure OpenAI Studio.

Step 2: Store your API key in Port secrets

Store your Azure OpenAI API key in Port's secrets system.

  1. In your Port application, click on your profile picture .
  2. Click on Credentials.
  3. Click on the Secrets tab.
  4. Click on + Secret and add your secret(s).

For provider-specific secret requirements and examples, see Step 2: Store API Keys in Secrets.

Secret naming flexibility

You can choose any names for your secrets. The examples are suggestions. Use names that make sense for your organization, and reference the exact names in your provider configuration.

For more details on managing secrets, see the Port Secrets documentation.

Step 3: Register Azure OpenAI with the Port API

Call the Create or connect an LLM provider API with validate_connection=true to test your configuration. Set provider to "azure-openai" and provide your Azure OpenAI endpoint, deployment name, and the secret name you created in Step 2.

{
"provider": "azure-openai",
"enabled": true,
"config": {
"apiKeySecretName": "azure-openai-api-key",
"endpoint": "https://your-resource-name.openai.azure.com",
"deploymentName": "your-deployment-name"
}
}

Replace your-resource-name with your actual Azure OpenAI resource name and your-deployment-name with your model deployment name.

API version

Port uses the appropriate Azure OpenAI API version automatically. You don't need to specify the API version in your configuration.

Step 4: Validate the configuration

The validate_connection=true parameter tests your configuration by making a request to your provider. If validation succeeds, your provider configuration is saved. If it fails, check the error message for details.

For more troubleshooting steps, see the Setup & Configuration guide.

Common validation failures:

  • Invalid API key: Verify your API key is correct and active in the Azure portal.
  • Incorrect endpoint: Ensure the endpoint URL matches your Azure OpenAI resource's endpoint (including the resource name).
  • Invalid deployment name: Verify the deployment name exists in your Azure OpenAI Studio.
  • Insufficient quota: Ensure your Azure OpenAI deployment has sufficient quota allocated.

After registration

Once your provider is configured:

For more information on provider selection and validation flow, see Setup & Configuration.