Skip to content

Commit 8f3fcb8

Browse files
authored
Merge branch 'main' into partners-kendrick-batch2
2 parents 26e7d1f + da4fd28 commit 8f3fcb8

1,641 files changed

Lines changed: 29702 additions & 12478 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.openpublishing.publish.config.json

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -506,6 +506,18 @@
506506
"branch": "dev",
507507
"branch_mapping": {}
508508
},
509+
{
510+
"path_to_root": "functions-nodejs-extensions",
511+
"url": "https://github.com/Azure/azure-functions-nodejs-extensions",
512+
"branch": "main",
513+
"branch_mapping": {}
514+
},
515+
{
516+
"path_to_root": "functions-node-sdk-bindings-blob",
517+
"url": "https://github.com/Azure-Samples/azure-functions-blob-sdk-bindings-nodejs",
518+
"branch": "main",
519+
"branch_mapping": {}
520+
},
509521
{
510522
"path_to_root": "functions-python-tensorflow-tutorial",
511523
"url": "https://github.com/Azure-Samples/functions-python-tensorflow-tutorial",
@@ -543,7 +555,24 @@
543555
"branch_mapping": {}
544556
},
545557
{
546-
"path_to_root": "functions-sql-todo-sample",
558+
"path_to_root": "functions-scenarios-durable-dotnet",
559+
"url": "https://github.com/Azure-Samples/durable-functions-quickstart-dotnet-azd",
560+
"branch": "main",
561+
"branch_mapping": {}
562+
},
563+
{
564+
"path_to_root": "functions-scenarios-durable-typescript",
565+
"url": "https://github.com/Azure-Samples/durable-functions-quickstart-typescript-azd",
566+
"branch": "main",
567+
"branch_mapping": {}
568+
},
569+
{
570+
"path_to_root": "functions-scenarios-durable-python",
571+
"url": "https://github.com/Azure-Samples/durable-functions-quickstart-python-azd",
572+
"branch": "main",
573+
"branch_mapping": {}
574+
},
575+
{ "path_to_root": "functions-sql-todo-sample",
547576
"url": "https://github.com/Azure-Samples/azure-sql-binding-func-dotnet-todo",
548577
"branch": "docs-snippets",
549578
"branch_mapping": {}

.openpublishing.redirection.json

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5064,6 +5064,16 @@
50645064
"redirect_url": "/azure/role-based-access-control/quickstart-role-assignments-template",
50655065
"redirect_document_id": true
50665066
},
5067+
{
5068+
"source_path_from_root": "/articles/role-based-access-control/built-in-roles/mixed-reality.md",
5069+
"redirect_url": "/azure/role-based-access-control/built-in-roles",
5070+
"redirect_document_id": false
5071+
},
5072+
{
5073+
"source_path_from_root": "/articles/role-based-access-control/permissions/mixed-reality.md",
5074+
"redirect_url": "/azure/role-based-access-control/resource-provider-operations",
5075+
"redirect_document_id": false
5076+
},
50675077
{
50685078
"source_path_from_root": "/articles/scheduler/get-started-portal.md",
50695079
"redirect_url": "/azure/scheduler/migrate-from-scheduler-to-logic-apps",
@@ -6559,6 +6569,11 @@
65596569
"source_path": "articles/dns/dns-sdk.md",
65606570
"redirect_url": "https://learn.microsoft.com/dotnet/api/overview/azure/resourcemanager.dns-readme",
65616571
"redirect_document_id": false
6572+
},
6573+
{
6574+
"source_path": "articles/oracle/oracle-db/exadata-vm-clusters.md",
6575+
"redirect_url": "/azure/oracle/oracle-db/database-overview",
6576+
"redirect_document_id": false
65626577
}
65636578

65646579
]

articles/active-directory-b2c/partner-asignio.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ The following diagram illustrates the implementation.
7676

7777
## Configure an application with Asignio
7878

79-
Configurating an application with Asignio is with the Asignio Partner Administration site.
79+
Configuring an application with Asignio is with the Asignio Partner Administration site.
8080

8181
1. To request access for your organization, go to asignio.com [Asignio Partner Administration](https://partner.asignio.com) page.
8282
2. With credentials, sign into Asignio Partner Administration.

articles/api-management/TOC.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -260,8 +260,8 @@
260260
href: amazon-bedrock-passthrough-llm-api.md
261261
- name: Semantic caching for LLM API requests
262262
href: azure-openai-enable-semantic-caching.md
263-
- name: Authenticate and authorize to Azure OpenAI
264-
href: api-management-authenticate-authorize-azure-openai.md
263+
- name: Authenticate and authorize to LLM APIs
264+
href: api-management-authenticate-authorize-ai-apis.md
265265
- name: Log LLM tokens, requests, and responses
266266
href: api-management-howto-llm-logs.md
267267
- name: Manage AI tools and agents

articles/api-management/api-management-authenticate-authorize-azure-openai.md renamed to articles/api-management/api-management-authenticate-authorize-ai-apis.md

Lines changed: 32 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,59 +1,59 @@
11
---
2-
title: Authenticate to Azure OpenAI API - Azure API Management
2+
title: Authenticate and Authorize to LLM APIs - Azure API Management
33
titleSuffix: Azure API Management
4-
description: Options to authenticate and authorize to Azure OpenAI APIs using Azure API Management. Includes API key, managed identity, and OAuth 2.0 authorization.
4+
description: Options to authenticate and authorize to LLM APIs using Azure API Management. Includes API key, managed identity, and OAuth 2.0 authorization.
55
author: dlepow
66
ms.service: azure-api-management
77
ms.topic: concept-article
8-
ms.date: 04/01/2025
8+
ms.date: 12/19/2025
99
ms.update-cycle: 180-days
1010
ms.author: danlep
1111
ms.collection: ce-skilling-ai-copilot
1212
---
1313

14-
# Authenticate and authorize access to Azure OpenAI APIs using Azure API Management
14+
# Authenticate and authorize access to LLM APIs by using Azure API Management
1515

1616
[!INCLUDE [api-management-availability-all-tiers](../../includes/api-management-availability-all-tiers.md)]
1717

18-
In this article, you learn about ways to authenticate and authorize to Azure OpenAI API endpoints that are managed using Azure API Management. This article shows the following common methods:
18+
In this article, you learn how to authenticate and authorize access to AI API endpoints that Azure API Management manages. This article shows the following common methods:
1919

20-
* **Authentication** - Authenticate to an Azure OpenAI API using policies that authenticate using either an API key or a Microsoft Entra ID managed identity.
20+
* **Authentication** - Authenticate to an AI API by using policies that use either an API key or a Microsoft Entra ID managed identity.
2121

2222
* **Authorization** - For more fine-grained access control, preauthorize requests that pass OAuth 2.0 tokens generated by an identity provider such as Microsoft Entra ID.
2323

2424
For background, see:
2525

26-
* [Azure OpenAI Service REST API reference](/azure/ai-foundry/openai/reference)
27-
2826
* [Authentication and authorization to APIs in API Management](authentication-authorization-overview.md).
2927

3028
## Prerequisites
3129

32-
Before following the steps in this article, you must have:
30+
To follow the examples in this article, you must have:
3331

3432
- An API Management instance. For example steps, see [Create an Azure API Management instance](get-started-create-service-instance.md).
35-
- An Azure OpenAI resource and model added to your API Management instance. For example steps, see [Import an Azure OpenAI API as a REST API](azure-openai-api-from-specification.md).
36-
- Permissions to create an app registration in an identity provider such as a Microsoft Entra tenant associated with your Azure subscription (for OAuth 2.0 authorization).
33+
- An AI model deployment added to your API Management instance as an AI. For example steps, see [Import a Microsoft Foundry API](azure-ai-foundry-api.md) or [Import a language model API](openai-compatible-llm-api.md).
34+
- (For OAuth 2.0 authorization) Permissions to create an app registration in an identity provider such as a Microsoft Entra ID tenant associated with your Azure subscription.
3735

38-
## Authenticate with API key
36+
## Authenticate by using API key
3937

40-
A default way to authenticate to an Azure OpenAI API is by using an API key. For this type of authentication, all API requests must include a valid API key in the `api-key` HTTP header.
38+
A default way to authenticate to an AI API is by using an API key. For this type of authentication, all API requests must include a valid API key in an HTTP header. The header name depends on the API. For example, Azure OpenAI in Microsoft Foundry APIs use the `api-key` header.
4139

42-
* API Management can manage the API key in a secure way, by using a [named value](api-management-howto-properties.md).
43-
* The named value can then be referenced in an API policy to set the `api-key` header in requests to the Azure OpenAI API. We provide two examples of how to do this: one uses the [`set-backend-service`](set-backend-service-policy.md) policy, and the other uses the [`set-header`](set-header-policy.md) policy.
40+
* API Management can manage the API key in a secure way by using a [named value](api-management-howto-properties.md).
41+
* You can reference the named value in an API policy to set the `api-key` header in requests to the API. The following two examples show how to do this: one uses the [`set-backend-service`](set-backend-service-policy.md) policy, and the other uses the [`set-header`](set-header-policy.md) policy.
4442

4543
### Store the API key in a named value
4644

47-
1. Obtain an API key from the Azure OpenAI resource. In the Azure portal, find a key on the **Keys and Endpoint** page of the Azure OpenAI resource.
45+
Here's an example of how to store an Azure OpenAI API key in a named value in API Management:
46+
47+
1. Get an API key from the AI model deployment. For an Azure OpenAI model deployment, find this information on the **Home** page for your project in the Microsoft Foundry portal.
4848
1. Go to your API Management instance, and select **Named values** in the left menu.
49-
1. Select **+ Add**, and add the value as a secret, or optionally for more security, use a [key vault reference](api-management-howto-properties.md#key-vault-secrets).
49+
1. Select **+ Add**, and add the value as a secret. For more security, optionally use a [key vault reference](api-management-howto-properties.md#key-vault-secrets).
5050

5151
### Pass the API key in API requests - set-backend-service policy
5252

5353
1. Create a [backend](backends.md) that points to the Azure OpenAI API.
5454
1. In the left menu of your API Management instance, select **Backends**.
5555
1. Select **+ Add**, and enter a descriptive name for the backend. Example: *openai-backend*.
56-
1. Under **Type**, select **Custom**, and enter the URL of the Azure OpenAI endpoint. Example: `https://contoso.openai.azure.com/openai`.
56+
1. Under **Type**, select **Custom**, and enter the URL of the Azure OpenAI endpoint. Example: `https://contoso.services.ai.azure.com/openai`.
5757
1. Under **Authorization credentials**, select **Headers**, and enter *api-key* as the header name and the named value as the value.
5858
1. Select **Create**.
5959
1. Add the following `set-backend-service` policy snippet in the `inbound` policy section to pass the API key in requests to the Azure OpenAI API.
@@ -76,19 +76,18 @@ In this example, the named value in API Management is *openai-api-key*.
7676
</set-header>
7777
```
7878

79-
8079
## Authenticate with managed identity
8180

82-
An alternative and recommended way to authenticate to an Azure OpenAI API is by using a managed identity in Microsoft Entra ID. For background, see
83-
[How to configure Azure OpenAI Service with managed identity](/azure/api-management/api-management-authenticate-authorize-azure-openai).
81+
For Azure OpenAI and other model deployments in Microsoft Foundry, use a managed identity in Microsoft Entra ID to authenticate. For background, see
82+
[How to configure Azure OpenAI in Microsoft Foundry Models with Microsoft Entra ID authentication](/azure/ai-foundry/openai/how-to/managed-identity).
8483

85-
Following are steps to configure your API Management instance to use a managed identity to authenticate requests to an Azure OpenAI API.
84+
Follow these steps to configure your API Management instance to use a managed identity for authentication.
8685

87-
1. [Enable](api-management-howto-use-managed-service-identity.md) a system-assigned or user-assigned managed identity for your API Management instance. The following example assumes that you've enabled the instance's system-assigned managed identity.
86+
1. [Enable](api-management-howto-use-managed-service-identity.md) a system-assigned or user-assigned managed identity for your API Management instance. The following example assumes that you enabled the instance's system-assigned managed identity.
8887

89-
1. Assign the managed identity the **Cognitive Services OpenAI User** role, scoped to the appropriate resource. For example, assign the system-assigned managed identity the **Cognitive Services OpenAI User** role on the Azure OpenAI resource. For detailed steps, see [Role-based access control for Azure OpenAI service](/azure/ai-foundry/openai/how-to/role-based-access-control).
88+
1. Assign the managed identity the **Cognitive Services OpenAI User** role, scoped to the appropriate resource. For example, assign the system-assigned managed identity the **Cognitive Services OpenAI User** role on the Microsoft Foundry resource. For detailed steps, see [Role-based access control for Azure OpenAI service](/azure/ai-foundry/openai/how-to/role-based-access-control).
9089

91-
1. Add the following policy snippet in the `inbound` policy section to authenticate requests to the Azure OpenAI API using the managed identity.
90+
1. Add the following policy snippet in the `inbound` policy section to authenticate requests to the API by using the managed identity.
9291

9392
In this example:
9493

@@ -101,22 +100,22 @@ Following are steps to configure your API Management instance to use a managed i
101100
<value>@("Bearer " + (string)context.Variables["managed-id-access-token"])</value>
102101
</set-header>
103102
```
104-
103+
105104
> [!TIP]
106-
> An alternative to using the `authentication-managed-identity` and `set-header` policies shown in this example is to configure a [backend](backends.md) resource that directs API requests to the Azure OpenAI Service endpoint. In the backend configuration, enable managed identity authentication to the Azure OpenAI Service. Azure API Management automates these steps when importing an API directly from Azure OpenAI Service. For more information, see [Import API from Azure OpenAI Service](azure-openai-api-from-specification.md#option-1-import-api-from-azure-openai).
105+
> Instead of using the `authentication-managed-identity` and `set-header` policies shown in this example, you can configure a [backend](backends.md) resource that directs API requests to the AI service endpoint. In the backend configuration, configure managed identity credentials to the `https://cognitiveservices.azure.com/` resource. Azure API Management automates these steps when you [import an API directly from Microsoft Foundry](azure-ai-foundry-api.md).
107106

108-
## OAuth 2.0 authorization using identity provider
107+
## OAuth 2.0 authorization by using identity provider
109108

110-
To enable more fine-grained access to OpenAPI APIs by particular users or clients, you can preauthorize access to the Azure OpenAI API using OAuth 2.0 authorization with Microsoft Entra ID or another identity provider. For background, see [Protect an API in Azure API Management using OAuth 2.0 authorization with Microsoft Entra ID](api-management-howto-protect-backend-with-aad.md).
109+
To enable more fine-grained access to Azure OpenAPI or other LLM APIs by particular users or clients, preauthorize access to the API by using OAuth 2.0 authorization with Microsoft Entra ID or another identity provider. For background, see [Protect an API in Azure API Management using OAuth 2.0 authorization with Microsoft Entra ID](api-management-howto-protect-backend-with-aad.md).
111110

112111
> [!NOTE]
113112
> Use OAuth 2.0 authorization as part of a defense-in-depth strategy. It's not a replacement for API key authentication or managed identity authentication to an Azure OpenAI API.
114113

115-
Following are high level steps to restrict API access to users or apps that are authorized using an identity provider.
114+
The following steps show how to restrict API access to users or apps that are authorized by using an identity provider.
116115

117-
1. Create an application in your identity provider to represent the OpenAI API in Azure API Management. If you're using Microsoft Entra ID, [register](api-management-howto-protect-backend-with-aad.md#register-an-application-in-microsoft-entra-id-to-represent-the-api) an application in your Microsoft Entra ID tenant. Record details such as the application ID and the audience URI.
116+
1. Create an application in your identity provider to represent the AI API in Azure API Management. If you're using Microsoft Entra ID, [register](api-management-howto-protect-backend-with-aad.md#register-an-application-in-microsoft-entra-id-to-represent-the-api) an application in your Microsoft Entra ID tenant. Record details such as the application ID and the audience URI.
118117

119-
As needed, configure the application to have roles or scopes that represent the fine-grained permissions needed to access the Azure OpenAI API.
118+
As needed, configure the application to have roles or scopes that represent the fine-grained permissions needed to access the AI API.
120119

121120
1. Add an `inbound` policy snippet in your API Management instance to validate requests that present a JSON web token (JWT) in the `Authorization` header. Place this snippet *before* other `inbound` policies that you set to authenticate to the Azure OpenAI API.
122121

@@ -164,4 +163,4 @@ Following are high level steps to restrict API access to users or apps that are
164163
## Related content
165164

166165
* Learn more about [Microsoft Entra ID and OAuth2.0](/entra/architecture/auth-oauth2).
167-
* [Authenticate requests to Azure AI services](/azure/ai-services/authentication)
166+
* [Authenticate requests to Foundry tools](/azure/ai-services/authentication)

0 commit comments

Comments
 (0)