Skip to content

Commit 3b55658

Browse files
committed
retrieve resource info for JS and TS
1 parent 699dc68 commit 3b55658

17 files changed

+72
-48
lines changed

articles/ai-services/openai/includes/assistants-javascript.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,11 @@ ms.custom: passwordless-ts, devex-track-js
2222
- We recommend reviewing the [Responsible AI transparency note](/legal/cognitive-services/openai/transparency-note?context=%2Fazure%2Fai-services%2Fopenai%2Fcontext%2Fcontext&tabs=text) and other [Responsible AI resources](/legal/cognitive-services/openai/overview?context=%2Fazure%2Fai-services%2Fopenai%2Fcontext%2Fcontext) to familiarize yourself with the capabilities and limitations of the Azure OpenAI Service.
2323
- An Azure OpenAI resource with the `gpt-4 (1106-preview)` model deployed was used testing this example.
2424

25-
## Microsoft Entra ID authentication is recommended
25+
### Microsoft Entra ID prerequisites
2626

27-
For _keyless_ authentication, you need to
28-
29-
1. Use the `@azure/identity` package.
30-
1. Assign the `Cognitive Services User` role to your user account. This can be done in the Azure portal under **Access control (IAM)** > **Add role assignment**.
31-
1. Sign in with the Azure CLI such as `az login`.
27+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
28+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
29+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
3230

3331
## Set up
3432

articles/ai-services/openai/includes/assistants-typescript.md

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,11 @@ ms.custom: passwordless-js, devex-track-typescript
2323
- We recommend reviewing the [Responsible AI transparency note](/legal/cognitive-services/openai/transparency-note?context=%2Fazure%2Fai-services%2Fopenai%2Fcontext%2Fcontext&tabs=text) and other [Responsible AI resources](/legal/cognitive-services/openai/overview?context=%2Fazure%2Fai-services%2Fopenai%2Fcontext%2Fcontext) to familiarize yourself with the capabilities and limitations of the Azure OpenAI Service.
2424
- An Azure OpenAI resource with the `gpt-4 (1106-preview)` model deployed was used testing this example.
2525

26-
## Passwordless authentication is recommended
26+
### Microsoft Entra ID prerequisites
2727

28-
For passwordless authentication, you need to:
29-
30-
1. Use the `@azure/identity` package.
31-
1. Assign the `Cognitive Services User` role to your user account. This can be done in the Azure portal under **Access control (IAM)** > **Add role assignment**.
32-
1. Sign in with the Azure CLI such as `az login`.
28+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
29+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
30+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
3331

3432
## Set up
3533

@@ -65,8 +63,6 @@ For passwordless authentication, you need to:
6563
npm install @azure/identity
6664
```
6765

68-
69-
7066
## Retrieve resource information
7167

7268
[!INCLUDE [resource authentication](resource-auth.md)]

articles/ai-services/openai/includes/chatgpt-javascript.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,11 @@ ms.date: 10/22
2323
- [Azure CLI](/cli/azure/install-azure-cli) used for passwordless authentication in a local development environment, create the necessary context by signing in with the Azure CLI.
2424
- An Azure OpenAI Service resource with either a `gpt-35-turbo` or `gpt-4` series models deployed. For more information about model deployment, see the [resource deployment guide](../how-to/create-resource.md).
2525

26+
### Microsoft Entra ID prerequisites
2627

28+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
29+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
30+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
2731

2832
## Retrieve resource information
2933

articles/ai-services/openai/includes/chatgpt-typescript.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,17 @@ ms.date: 10/22
1818
1919
## Prerequisites
2020

21-
2221
- An Azure subscription - [Create one for free](https://azure.microsoft.com/free/cognitive-services?azure-portal=true)
2322
- [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule)
2423
- [TypeScript](https://www.typescriptlang.org/download/)
2524
- [Azure CLI](/cli/azure/install-azure-cli) used for passwordless authentication in a local development environment, create the necessary context by signing in with the Azure CLI.
2625
- An Azure OpenAI Service resource with a `gpt-35-turbo` or `gpt-4` series models deployed. For more information about model deployment, see the [resource deployment guide](../how-to/create-resource.md).
2726

27+
### Microsoft Entra ID prerequisites
28+
29+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
30+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
31+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
2832

2933
## Retrieve resource information
3034

articles/ai-services/openai/includes/dall-e-javascript.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,16 @@ Use this guide to get started generating images with the Azure OpenAI SDK for Ja
1717

1818
## Prerequisites
1919

20-
2120
- An Azure subscription - [Create one for free](https://azure.microsoft.com/free/cognitive-services?azure-portal=true)
2221
- [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule)
2322
- [Azure CLI](/cli/azure/install-azure-cli) used for passwordless authentication in a local development environment, create the necessary context by signing in with the Azure CLI.
2423
- An Azure OpenAI resource created in a supported region (see [Region availability](/azure/ai-services/openai/concepts/models#model-summary-table-and-region-availability)). For more information, see [Create a resource and deploy a model with Azure OpenAI](../how-to/create-resource.md).
2524

25+
### Microsoft Entra ID prerequisites
26+
27+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
28+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
29+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
2630

2731
## Retrieve resource information
2832

articles/ai-services/openai/includes/dall-e-typescript.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,13 +17,17 @@ Use this guide to get started generating images with the Azure OpenAI SDK for Ja
1717

1818
## Prerequisites
1919

20-
2120
- An Azure subscription - [Create one for free](https://azure.microsoft.com/free/cognitive-services?azure-portal=true)
2221
- [LTS versions of Node.js](https://github.com/nodejs/release#release-schedule)
2322
- [TypeScript](https://www.typescriptlang.org/download/)
2423
- [Azure CLI](/cli/azure/install-azure-cli) used for passwordless authentication in a local development environment, create the necessary context by signing in with the Azure CLI.
2524
- An Azure OpenAI resource created in a supported region (see [Region availability](/azure/ai-services/openai/concepts/models#model-summary-table-and-region-availability)). For more information, see [Create a resource and deploy a model with Azure OpenAI](../how-to/create-resource.md).
2625

26+
### Microsoft Entra ID prerequisites
27+
28+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
29+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
30+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
2731

2832
## Retrieve resource information
2933

articles/ai-services/openai/includes/gpt-v-javascript.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,14 @@ This SDK is provided by OpenAI with Azure specific types provided by Azure.
2323
- [Azure CLI](/cli/azure/install-azure-cli) used for passwordless authentication in a local development environment, create the necessary context by signing in with the Azure CLI.
2424
- An Azure OpenAI resource created in a supported region (see [Region availability](/azure/ai-services/openai/concepts/models#model-summary-table-and-region-availability)). For more information, see [Create a resource and deploy a model with Azure OpenAI](../how-to/create-resource.md).
2525

26-
---
27-
2826
> [!NOTE]
2927
> This library is maintained by OpenAI. Refer to the [release history](https://github.com/openai/openai-node/releases) to track the latest updates to the library.
3028
29+
### Microsoft Entra ID prerequisites
30+
31+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
32+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
33+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
3134

3235
## Retrieve resource information
3336

articles/ai-services/openai/includes/gpt-v-typescript.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,14 @@ This SDK is provided by OpenAI with Azure specific types provided by Azure.
2424
- [Azure CLI](/cli/azure/install-azure-cli) used for passwordless authentication in a local development environment, create the necessary context by signing in with the Azure CLI.
2525
- An Azure OpenAI resource created in a supported region (see [Region availability](/azure/ai-services/openai/concepts/models#model-summary-table-and-region-availability)). For more information, see [Create a resource and deploy a model with Azure OpenAI](../how-to/create-resource.md).
2626

27-
2827
> [!NOTE]
2928
> This library is maintained by OpenAI. Refer to the [release history](https://github.com/openai/openai-node/releases) to track the latest updates to the library.
3029
30+
### Microsoft Entra ID prerequisites
31+
32+
For the recommended keyless authentication with Microsoft Entra ID, you need to:
33+
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.
34+
- Assign the `Cognitive Services User` role to your user account. You can assign roles in the Azure portal under **Access control (IAM)** > **Add role assignment**.
3135

3236
## Retrieve resource information
3337

articles/ai-services/openai/includes/realtime-javascript.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ ms.date: 12/26/2024
1414
- An Azure OpenAI resource created in the East US 2 or Sweden Central regions. See [Region availability](/azure/ai-services/openai/concepts/models#model-summary-table-and-region-availability).
1515
- Then, you need to deploy a `gpt-4o-realtime-preview` model with your Azure OpenAI resource. For more information, see [Create a resource and deploy a model with Azure OpenAI](../how-to/create-resource.md).
1616

17-
## Microsoft Entra ID prerequisites
17+
### Microsoft Entra ID prerequisites
1818

1919
For the recommended keyless authentication with Microsoft Entra ID, you need to:
2020
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.

articles/ai-services/openai/includes/realtime-typescript.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ ms.date: 12/26/2024
1515
- An Azure OpenAI resource created in the East US 2 or Sweden Central regions. See [Region availability](/azure/ai-services/openai/concepts/models#model-summary-table-and-region-availability).
1616
- Then, you need to deploy a `gpt-4o-realtime-preview` model with your Azure OpenAI resource. For more information, see [Create a resource and deploy a model with Azure OpenAI](../how-to/create-resource.md).
1717

18-
## Microsoft Entra ID prerequisites
18+
### Microsoft Entra ID prerequisites
1919

2020
For the recommended keyless authentication with Microsoft Entra ID, you need to:
2121
- Install the [Azure CLI](/cli/azure/install-azure-cli) used for keyless authentication with Microsoft Entra ID.

0 commit comments

Comments
 (0)