Skip to content

Commit ca8c8e0

Browse files
authored
Merge pull request #2 from aahill/patch-12
Update openapi-spec-samples.md
2 parents 9dd6de5 + f740371 commit ca8c8e0

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

articles/ai-services/agents/how-to/tools/openapi-spec-samples.md

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Use this article to find step-by-step instructions and code samples for using Op
2020
:::zone pivot="portal"
2121

2222
1. Go to the [Azure AI Foundry portal](https://ai.azure.com/). in the **Create and debug** screen or **Agent playground**, select your agent.
23-
1. Scroll down the **Setup** pane on the right to **action**. Then select **Add**.
23+
1. Scroll down the **Setup** pane to **action**. Then select **Add**.
2424

2525
:::image type="content" source="../../media/tools/action-tools.png" alt-text="A screenshot showing the available tool categories in the Azure AI Foundry portal." lightbox="../../media/tools/action-tools.png":::
2626

@@ -32,7 +32,7 @@ Use this article to find step-by-step instructions and code samples for using Op
3232

3333
:::image type="content" source="../../media/tools/open-api-details.png" alt-text="A screenshot showing the openAPI tool details in the Azure AI Foundry portal." lightbox="../../media/tools/open-api-details.png":::
3434

35-
1. Click Next and select your authentication method. Choose `connection` for `API key`.
35+
1. Select **Next** and select your authentication method. Choose `connection` for `API key`.
3636
1. If you choose `connection`, you need to select the custom keys connection you have created before.
3737
1. If you choose `managed identity`, you need to input the audience to get your token. An example of an audience would be `https://cognitiveservices.azure.com/` to connect to Azure AI Services. Make sure you have already set up authentication and role assignment (as described in the [section](./openapi-spec.md#authenticating-with-managed-identity-microsoft-entra-id) above).
3838

@@ -46,7 +46,7 @@ Use this article to find step-by-step instructions and code samples for using Op
4646

4747
## Using the .NET SDK
4848

49-
In this example we will demonstrate the possibility to use services with [OpenAPI Specification](https://en.wikipedia.org/wiki/OpenAPI_Specification) with the agent. We will use [wttr.in](https://wttr.in) service to get weather and its specification file [weather_openapi.json](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/ai/Azure.AI.Projects/tests/Samples/Agent/weather_openapi.json).
49+
In this example we'll demonstrate the possibility to use services with [OpenAPI Specification](https://en.wikipedia.org/wiki/OpenAPI_Specification) with the agent. We will use [wttr.in](https://wttr.in) service to get weather and its specification file [weather_openapi.json](https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/ai/Azure.AI.Projects/tests/Samples/Agent/weather_openapi.json).
5050

5151
1. First get `ProjectEndpoint` and `ModelDeploymentName` from config and create a `PersistentAgentsClient`. Also, create an `OpenApiAnonymousAuthDetails` and `OpenApiToolDefinition` from config.
5252

@@ -67,7 +67,7 @@ In this example we will demonstrate the possibility to use services with [OpenAP
6767
);
6868
```
6969

70-
2. Next we will need to create an agent.
70+
2. Next we'll need to create an agent.
7171

7272
```csharp
7373
PersistentAgent agent = client.CreateAgent(
@@ -78,7 +78,7 @@ In this example we will demonstrate the possibility to use services with [OpenAP
7878
);
7979
```
8080

81-
3. Now we will create a `ThreadRun` and wait until it is complete. If the run will not be successful, we will print the last error.
81+
3. Now we'll create a `ThreadRun` and wait until it is complete. If the run will not be successful, we'll print the last error.
8282

8383

8484
```csharp
@@ -121,7 +121,7 @@ In this example we will demonstrate the possibility to use services with [OpenAP
121121
}
122122
```
123123

124-
5. Finally, we delete all the resources, we have created in this sample.
124+
5. Finally, we delete all the resources we have created in this sample.
125125

126126
```csharp
127127
client.DeleteThread(thread.Id);
@@ -232,7 +232,7 @@ Create a run and observe that the model uses the OpenAPI Spec tool to provide a
232232

233233
:::zone pivot="rest-api"
234234

235-
## Step 1: Create the OpenAPI Spec tool definition, agent and thread
235+
## Step 1: Create the OpenAPI Spec tool definition, agent, and thread
236236

237237
You might want to store the OpenAPI specification in another file and import the content to initialize the tool. This example is using `anonymous` as the authentication type.
238238

@@ -366,4 +366,3 @@ curl $AZURE_AI_AGENTS_ENDPOINT/threads/thread_abc123/messages?api-version=2024-1
366366
```
367367

368368
:::zone-end
369-

0 commit comments

Comments
 (0)