Skip to content

Capabilities ​

@anvia/azure is a thin Azure configuration layer over the OpenAI adapters. Completion, embedding, image, speech, and transcription behavior is the same normalized mapping that @anvia/openai provides, applied to Azure deployments.

CapabilitySupport
Responses completion and streamingYes (api: 'responses')
Chat Completions and streamingYes (default)
Local Anvia tools and tool choiceYes
Structured outputWhere the deployment supports it
Reasoning contentWhere the deployment supports it
EmbeddingsYes
Image generation, speech, transcriptionWhere the deployment supports them
Model listingEndpoint model list, as azure-openai
API-key authenticationYes
Microsoft Entra token providerYes
Injected OpenAI SDK clientYes
Azure v1 endpoints (/openai/v1/)Yes
Foundry project endpointsYes, through baseUrl

Which APIs, tools, media options, and listing results work depends on your Azure endpoint and deployment. listModels() calls the endpoint's model listing API; it does not enumerate Azure Resource Manager deployments.

Azure Responses behavior ​

The Responses model extends the shared adapter that @anvia/openai/adapters exports and adds two Azure-specific behaviors:

  • Message item types. Conversation messages are sent with an explicit type: "message", which Foundry project endpoints require and resource endpoints accept. Function-call and tool-result items keep their own shapes.
  • Terminal tool-argument names. Azure streams may omit the function name from the terminal response.function_call_arguments.done event. The model resolves it from the earlier function-call item with the same item ID, keeping state local to each stream so parallel tool calls stay separate. A missing identity is rejected with a provider output error of kind invalid-tool-call, and a conflicting name is rejected rather than overwritten.

Completed tool calls remain validated by the shared parser. Final-only or encrypted reasoning that arrives only in the terminal Responses event, including on Azure streams, is retained by Core for later turns.

Provider identities ​

SurfaceIdentity
Completion, embedding, media handlesazure-openai
Chat Completions request traceazure-openai-chat
Responses request traceazure-openai-responses
Model listing errorsazure-openai

Not included ​

The package does not implement AI SDK-style Azure file-ID prefix inference, hosted-tool helpers, Azure Speech or MAI adapters, deployment management, or automatic credential discovery from environment variables.

Built for Anvia.