Azure OpenAI for .NET
Gives coding agents practical .NET patterns for Azure OpenAI integrations.
The skill exposes API-key, Entra ID, Azure AI Search key, and external Azure/OpenAI data flows, but does not explain data minimization, secret redaction, user confirmation, permission scope, cost controls, or rollback. It recommends Entra ID for production while still presenting direct key usage, so points are deducted.
The organization and main API paths are broadly consistent, and rate-limit handling is shown. However, examples contain undefined variables, package versions are not pinned, and there are no skill-specific key-path tests or thorough input/service-capability failure modes. Static calibration therefore keeps this at 7.
The audience, .NET SDK context, trigger terms, and chat/embedding/image/audio scenarios are fairly clear. Non-fit cases, deployment/version compatibility boundaries, Chinese-language guidance, and mainland-China reachability are not addressed; the skill also depends on external Azure/OpenAI services, so points are deducted.
The document has front matter, MIT licensing, author and version metadata, installation notes, structured examples, best practices, error handling, and reference links. It lacks a changelog, explicit maintenance owner/update path, FAQ, troubleshooting guidance, and dependency-version strategy, so it does not receive full marks.
It covers common .NET integration patterns and several snippets are directly adaptable. However, multiple examples omit surrounding declarations or project configuration, and no real outputs, verification results, or complete runnable sample are provided. Manual correction remains necessary; static calibration caps this at 6.
The skill includes NuGet, API, migration, quickstart, and source references, while the repository supplies generic CI and harness tests. There is no skill-specific committed test suite with execution evidence or independent corroboration, and this review did not execute code, so points are deducted.
- Variables such as endpoint, messages, and searchEndpoint are undefined; the snippets require surrounding project context before running.
- API keys should not appear in logs or source code, and the documentation should explicitly disclose that Azure/OpenAI requests may transmit and process user content.
- The reference links and “Current Version: 2.1.0” were not version-consistency-verified from the supplied static material; verify SDK APIs and deployment capabilities before use.
- Mainland-China network access, regional availability, data residency, and compliance constraints are not documented.
What it does & when to use it
This skill is for .NET developers using Azure.AI.OpenAI with Azure OpenAI and OpenAI-compatible services. It covers chat completions, streaming, multi-turn conversations, structured JSON output, reasoning models, embeddings, image generation, audio transcription, text-to-speech, and function calling. It also includes Azure AI Search retrieval-augmented generation, API-key and Microsoft Entra authentication, error handling, and client-reuse guidance. It is a strong fit for teams already building Azure OpenAI applications in .NET, but it does not provide complete deployment, pricing, or capacity-planning guidance.
It guides agents to install Azure.AI.OpenAI and, when needed, the OpenAI package with dotnet add package commands; configure endpoint, API key, deployment, and token-credential environment variables; and generate C# code using AzureOpenAIClient, ChatClient, EmbeddingClient, ImageClient, AudioClient, and AssistantClient. The examples submit chat messages, stream responses, parse JSON Schema output, generate embeddings and DALL-E images, transcribe audio, synthesize speech, declare function tools, and inspect tool calls. One example writes generated speech to a file. Another configures Azure AI Search as a chat data source and reads intent and citations.
- A .NET backend developer needs to add GPT-4 or GPT-4o chat completions through Azure OpenAI.
- An application team needs batch text embeddings for vector-search workflows.
- A developer needs Azure AI Search grounding and citation data in a conversational application.
- A .NET team is adding DALL-E image generation, Whisper transcription, or text-to-speech.
- A developer needs model function calling with explicit validation of tool arguments before execution.
Pros & cons
- Covers the main implementation paths for chat, embeddings, images, audio, and tool calls.
- Includes both API-key and Microsoft Entra authentication, with a production recommendation for Entra ID.
- Provides examples for structured outputs, streaming, multi-turn chat, Azure AI Search RAG, and error handling.
- Includes a client hierarchy, key-type reference, related SDKs, and follow-up documentation links.
- Examples require an Azure endpoint, model deployment, and suitable credentials before they can run.
- The SKILL.md does not cover complete application deployment, pricing, or capacity planning.
- Assistants are listed in the client hierarchy but lack a complete usage example.
- No independent test results or skill-specific test suite is shown in the supplied material.
How to install
Place the skill directory in the coding agent's skill directory: .github/plugins/azure-sdk-dotnet/skills/azure-ai-openai-dotnet/. The collection can be installed with npx skills add microsoft/skills and selected in the wizard, or the repository can be cloned and the required directory copied. For the project, run dotnet add package Azure.AI.OpenAI; for OpenAI non-Azure compatibility, also run dotnet add package OpenAI.
How to use
Set AZURE_OPENAI_ENDPOINT and AZURE_OPENAI_DEPLOYMENT_NAME in the .NET project environment. Set AZURE_OPENAI_API_KEY when using AzureKeyCredential, or configure AZURE_TOKEN_CREDENTIALS as needed when using DefaultAzureCredential in production. Then give the coding agent a request such as “Create a streaming gpt-4o-mini chat client in .NET with Azure.AI.OpenAI and DefaultAzureCredential.” The SKILL.md does not define a specific agent command or provide a complete project template.
Compared to similar skills
The skill distinguishes Azure.AI.OpenAI from the OpenAI package: the former is the Azure OpenAI client, while the latter provides OpenAI compatibility. It also identifies Azure.Identity for authentication and Azure.Search.Documents as the related SDK for AI Search integration.