You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -112,6 +112,21 @@ No installation is necessary to use the Azure AI Foundry portal.
112
112
> [!TIP]
113
113
> All the code in this article is at [GitHub Quickstart](https://github.com/azure-ai-foundry/foundry-samples/tree/main/samples/microsoft/csharp/mslearn-resources/quickstart).
114
114
115
+
# [REST API](#tab/rest)
116
+
117
+
1. [Install Azure CLI]()
118
+
1. Get a temporary access token. It will expire in 2 hours, you'll need to refresh after that.
119
+
120
+
```cli
121
+
az account get-access-token --scope https://ai.azure.com/.default
122
+
```
123
+
124
+
1. Save the results as the environment variable `AZURE_AI_AUTH_TOKEN`.
125
+
126
+
> [!TIP]
127
+
> All the code in this article is at [GitHub Quickstart](https://github.com/azure-ai-foundry/foundry-samples/tree/main/samples/microsoft/csharp/mslearn-resources/quickstart).
128
+
129
+
115
130
---
116
131
117
132
## Run a chat completion
@@ -146,6 +161,10 @@ Substitute your value for the endpoint in this code:
0 commit comments