Agents
Create an agent Create a new code-based agent
Creates a new agent or a new version of an existing agent. Creates a new code-based agent. Uploads the code zip and creates the agent in a single call.
The agent name is provided in the x-ms-agent-name header since POST /agents has no name in the URL path.
The SHA-256 hex digest of the zip is provided in the x-ms-code-zip-sha256 header for integrity and dedup.
The request body is multipart/form-data with a JSON metadata part and a binary code part (part order is irrelevant).
Maximum upload size is 250 MB.
Параметры заголовка
Foundry-Features
enum
A feature flag opt-in required when using preview operations or modifying persisted preview resources.
x-ms-agent-name
string
The unique name that identifies the agent. Max 63 chars, must start and end with alphanumeric, hyphens allowed in the middle.
x-ms-code-zip-sha256
string
SHA-256 hex digest of the uploaded code zip. Used for change detection (dedup) and integrity verification.
Параметры запроса
api-version
string
обязательно
The API version to use for this operation.
Текст запроса
The content multipart request content.
name
string
обязательно
The unique name that identifies the agent. Name can be used to retrieve/update/delete the agent. - Must start and end with alphanumeric characters, - Can contain hyphens in the middle - Must not exceed 63 characters.
state
string | enum
The operational state of an agent.
enum
metadata
object
Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format, and querying for objects via API or the dashboard. Keys are strings with a maximum length of 64 characters. Values are strings with a maximum length of 512 characters.
description
string
A human-readable description of the agent.
definition
hosted | prompt | workflow | external | voice
обязательно
hosted
HostedAgentDefinition
The hosted agent definition.
kind
enum
обязательно
cpu
string
обязательно
The CPU configuration for the hosted agent.
memory
string
обязательно
The memory configuration for the hosted agent.
environment_variables
object
Environment variables to set in the hosted agent container.
container_configuration
ContainerConfiguration
Container-based deployment configuration for a hosted agent.
image
string
обязательно
The container image for the hosted agent.
registry_connection_id
string
The id (or name) of the Foundry project connection that provides the credentials used to authenticate to the private container registry hosting image. The connection abstracts the auth mechanism — for example a managed-identity-federated token exchange, or a username/token secret — so registry credentials are never part of the agent definition. Omit for public images or registries already reachable by the platform's default identity (for example, Azure Container Registry).
protocol_versions
ProtocolVersionRecord[]
The protocols that the agent supports for ingress communication.
code_configuration
CodeConfiguration
Code-based deployment configuration for a hosted agent.
runtime
string
обязательно
The runtime identifier for code execution (e.g., 'python_3_11', 'python_3_12', 'python_3_13').
entry_point
string[]
обязательно
The entry point command and arguments for the code execution.
dependency_resolution
string | enum
обязательно
How package dependencies are resolved at deployment time for a code-based hosted agent.
enum
content_hash
string
The SHA-256 hex digest of the uploaded code zip. Set by the service from the x-ms-code-zip-sha256 request header; read-only in responses and never accepted in request payloads.
telemetry_config
TelemetryConfig
Customer-supplied telemetry configuration for exporting container logs, traces, and metrics.
endpoints
TelemetryEndpoint[]
обязательно
Customer-supplied telemetry export endpoint configurations.
session_configuration
SessionConfiguration
Session defaults applied to sessions created for a hosted agent version.
idle_timeout_seconds
integer
The idle duration, in seconds, before a session's sandbox is suspended. Optional — when unset, the server default of 900 seconds is used. Must be between 120 and 3600 seconds (inclusive).
prompt
PromptAgentDefinition
The prompt agent definition
kind
enum
обязательно
harness
github_copilot_preview
A managed runtime and agent loop used to execute a prompt agent.
github_copilot_preview
GitHubCopilotHarness
The GitHub Copilot managed harness for prompt agents.
type
enum
обязательно
The type of managed harness. Always github_copilot_preview.
model
string
обязательно
The model deployment to use for this agent.
instructions
string | null
A system (or developer) message inserted into the model's context.
skills
SkillReference[]
The Foundry skills available to this prompt agent. An omitted skill version is resolved and pinned when the agent version is created.
temperature
number | null
What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. We generally recommend altering this or top_p but not both. Defaults to 1.
top_p
number | null
An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. We generally recommend altering this or temperature but not both. Defaults to 1.
reasoning
OpenAI.Reasoning | null
Configuration options for reasoning models.
mode
string | enum
enum
effort
string | enum | null
Constrains effort on reasoning for reasoning models. Currently supported values are none, minimal, low, medium, high, xhigh, and max. Reducing reasoning effort can result in faster responses and fewer tokens used on reasoning in a response. Not all reasoning models support every value. See the reasoning guide for model-specific support.
enum
summary
enum
context
enum
generate_summary
enum
tools
OpenAI.Tool[]
An array of tools the model may call while generating a response. You can specify which tool to use by setting the tool_choice parameter.
tool_choice
string | OpenAI.ToolChoiceParam
How the model should select which tool (or tools) to use when generating a response. See the tools parameter to see how to specify which tools the model can call.
function
OpenAI.ToolChoiceFunction
Use this option to force the model to call a specific function.
type
enum
обязательно
For function calling, the type is always function.
name
string
обязательно
The name of the function to call.
mcp
OpenAI.ToolChoiceMCP
Use this option to force the model to call a specific tool on a remote MCP server.
type
enum
обязательно
For MCP tools, the type is always mcp.
server_label
string
обязательно
The label of the MCP server to use.
allowed_tools
OpenAI.ToolChoiceAllowed
Constrains the tools available to the model to a pre-defined set.
type
enum
обязательно
Allowed tool configuration type. Always allowed_tools.
mode
enum
обязательно
Constrains the tools available to the model to a pre-defined set. auto allows the model to pick from among the allowed tools and generate a message. required requires the model to call one or more of the allowed tools.
tools
object[]
обязательно
A list of tool definitions that the model should be allowed to call. For the Responses API, the list of tool definitions might look like: json [ { "type": "function", "name": "get_weather" }, { "type": "mcp", "server_label": "deepwiki" }, { "type": "image_generation" } ]
custom
OpenAI.ToolChoiceCustom
Use this option to force the model to call a specific custom tool.
type
enum
обязательно
For custom tool calling, the type is always custom.
name
string
обязательно
The name of the custom tool to call.
programmatic_tool_calling
OpenAI.SpecificProgrammaticToolCallingParam
type
enum
обязательно
The tool to call. Always programmatic_tool_calling.
apply_patch
OpenAI.SpecificApplyPatchParam
Forces the model to call the apply_patch tool when executing a tool call.
type
enum
обязательно
The tool to call. Always apply_patch.
shell
OpenAI.SpecificFunctionShellParam
Forces the model to call the shell tool when a tool call is required.
type
enum
обязательно
The tool to call. Always shell.
file_search
OpenAI.ToolChoiceFileSearch
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
web_search_preview
OpenAI.ToolChoiceWebSearchPreview
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
computer_use_preview
OpenAI.ToolChoiceComputerUsePreview
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
web_search_preview_2025_03_11
OpenAI.ToolChoiceWebSearchPreview20250311
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
image_generation
OpenAI.ToolChoiceImageGeneration
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
code_interpreter
OpenAI.ToolChoiceCodeInterpreter
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
computer
OpenAI.ToolChoiceComputer
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
computer_use
OpenAI.ToolChoiceComputerUse
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
text
PromptAgentDefinitionTextOptions
Configuration options for a text response from the model. Can be plain text or structured JSON data.
format
json_schema | text | json_object
An object specifying the format that the model must output. Configuring { "type": "json_schema" } enables Structured Outputs, which ensures the model will match your supplied JSON schema. Learn more in the Structured Outputs guide. The default format is { "type": "text" } with no additional options. Not recommended for gpt-4o and newer models:* Setting to { "type": "json_object" } enables the older JSON mode, which ensures the message the model generates is valid JSON. Using json_schema is preferred for models that support it.
json_schema
OpenAI.TextResponseFormatJsonSchema
JSON Schema response format. Used to generate structured JSON responses. Learn more about Structured Outputs.
type
enum
обязательно
The type of response format being defined. Always json_schema.
description
string
A description of what the response format is for, used by the model to determine how to respond in the format.
name
string
обязательно
The name of the response format. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
schema
OpenAI.ResponseFormatJsonSchemaSchema
обязательно
The schema for the response format, described as a JSON Schema object. Learn how to build JSON schemas here.
text
OpenAI.TextResponseFormatConfigurationResponseFormatText
Default response format. Used to generate text responses.
type
enum
обязательно
The type of response format being defined. Always text.
json_object
OpenAI.TextResponseFormatConfigurationResponseFormatJsonObject
JSON object response format. An older method of generating JSON responses. Using json_schema is recommended for models that support it. Note that the model will not generate JSON without a system or user message instructing it to do so.
type
enum
обязательно
The type of response format being defined. Always json_object.
structured_inputs
object
Set of structured inputs that can participate in prompt template substitution or tool argument bindings.
[key: string]
StructuredInputDefinition
An structured input that can participate in prompt template substitutions and tool argument binding.
description
string
A human-readable description of the input.
default_value
StructuredInputDefinition
The default value for the input if no run-time value is provided.
schema
object
The JSON schema for the structured input (optional).
required
boolean
Whether the input property is required when the agent is invoked. The service defaults to false if a value is not specified by the caller.
workflow
WorkflowAgentDefinition
The workflow agent definition. Microsoft Foundry is retiring workflows on December 1, 2026. If you're looking to build new workflows, use Microsoft Agent Framework. To migrate existing workflows, see the Migration guide.
kind
enum
обязательно
workflow
string
The CSDL YAML definition of the workflow.
external
ExternalAgentDefinition
The external agent definition. Represents a third-party agent hosted outside Foundry (for example, on GCP or AWS). Registration is metadata-only: Foundry records the agent definition to light up observability experiences (traces, evaluations) over customer-emitted OpenTelemetry data.
kind
enum
обязательно
otel_agent_id
string
The OpenTelemetry agent identifier used to attribute customer-emitted spans to this Foundry agent. Spans must include the attribute gen_ai.agent.id = <otel_agent_id> to appear under this registration. Defaults to the top-level agent name when omitted. Provide an explicit value only for migration scenarios where the running external agent already emits a stable id that differs from the Foundry agent name. The resolved value is always echoed on read.
voice
VoiceAgentDefinition
The voice agent definition. Its configuration (model, instructions, audio, tools, and optional avatar) drives a managed speech-to-speech experience. Establish realtime voice sessions through GET /agents/{agent_name}/endpoint/protocols/voice. Every create or update produces a new immutable version.
kind
enum
обязательно
The kind discriminator for a voice agent definition. Always voice.
model_type
string | enum
How the model backing a voice agent is served. This is independent of the architecture (realtime or cascaded), which the service derives from the selected model.
enum
model
string
The model to use for this agent. Required with model_type for a model-backed voice agent and omitted when conversation_engine is provided. The model must support realtime or cascaded voice.
conversation_engine
hosted_agent
An engine that owns conversation handling for a voice agent.
hosted_agent
VoiceHostedAgentConversationEngine
A closed reference to the hosted text agent that owns conversation handling for a voice agent. The hosted agent is resolved within the same project and must support the invocations_ws protocol, Voice Live compatibility, and Bridge Protocol 1.0.
type
enum
обязательно
Selects a hosted Foundry agent as the conversation engine.
name
string
обязательно
The non-empty DNS-like name of the target hosted text agent in the same project.
version
string
The target agent version. Omit this property to select the latest version when the voice session starts. When supplied, use a positive integer or draft-{positive-unix-timestamp} whose numeric component fits in a signed 64-bit integer.
instructions
string
A system (or developer) message inserted into the model's context. Supports template substitution via structured_inputs, rendered per session before the live session starts.
greeting
template | llm_generated
Session-start greeting configuration for a voice agent.
template
VoiceAgentTemplateGreetingConfig
A deterministic greeting rendered with the voice agent's structured inputs and synthesized without model-authored generation.
type
enum
обязательно
text
string
обязательно
The Handlebars text template spoken at session start.
llm_generated
VoiceAgentLlmGeneratedGreetingConfig
A greeting authored by the session model from a scoped opening-turn prompt.
type
enum
обязательно
prompt
string
обязательно
The Handlebars prompt that guides the opening turn.
tool_choice
enum | OpenAI.ToolChoiceFunction | OpenAI.ToolChoiceMCP
Tool-selection behavior for a voice agent.
enum
type
enum
обязательно
For function calling, the type is always function.
name
string
обязательно
The name of the function to call.
type
enum
обязательно
For MCP tools, the type is always mcp.
server_label
string
обязательно
The label of the MCP server to use.
audio
VoiceAgentAudioConfig
The audio configuration for a voice agent. These values are session defaults and may be overridden when connecting.
input
VoiceAgentAudioInputConfig
Input audio configuration for a voice agent.
format
audio/pcm | audio/pcmu | audio/pcma
audio/pcm
OpenAI.RealtimeAudioFormatsAudioPcm
type
enum
обязательно
rate
enum
audio/pcmu
OpenAI.RealtimeAudioFormatsAudioPcmu
type
enum
обязательно
audio/pcma
OpenAI.RealtimeAudioFormatsAudioPcma
type
enum
обязательно
noise_reduction
VoiceAgentNoiseReduction | null
Input noise reduction. Set to null to disable.
type
string | enum
обязательно
The input audio noise reduction mode.
enum
turn_detection
server_vad | azure_semantic_vad | azure_semantic_vad_en | azure_semantic_vad_multilingual | semantic_vad | null
Turn (end-of-speech) detection. Server-side turn detection is enabled by default; set to null to disable it, in which case the client must trigger responses manually.
server_vad
VoiceAgentServerVadTurnDetection
Server-side voice activity detection.
type
enum
обязательно
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
azure_semantic_vad
VoiceAgentAzureSemanticVadTurnDetection
Azure semantic voice activity detection.
type
enum
обязательно
threshold
number
Activation threshold for voice activity detection, from 0 to 1.
prefix_padding_ms
integer
A duration encoded as an integer number of milliseconds.
silence_duration_ms
integer
A duration encoded as an integer number of milliseconds.
idle_timeout_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
remove_filler_words
boolean
Whether filler words are removed from transcription.
create_response
boolean
Whether a response is created automatically when speech stops.
interrupt_response
boolean
Whether user speech may interrupt the agent's response.
languages
string[]
BCP-47 language codes used for speech detection.
azure_semantic_vad_en
VoiceAgentAzureSemanticVadEnTurnDetection
English-optimized Azure semantic voice activity detection.
type
enum
обязательно
threshold
number
Activation threshold for voice activity detection, from 0 to 1.
prefix_padding_ms
integer
A duration encoded as an integer number of milliseconds.
silence_duration_ms
integer
A duration encoded as an integer number of milliseconds.
idle_timeout_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
remove_filler_words
boolean
Whether filler words are removed from transcription.
create_response
boolean
Whether a response is created automatically when speech stops.
interrupt_response
boolean
Whether user speech may interrupt the agent's response.
azure_semantic_vad_multilingual
VoiceAgentAzureSemanticVadMultilingualTurnDetection
Multilingual Azure semantic voice activity detection.
type
enum
обязательно
threshold
number
Activation threshold for voice activity detection, from 0 to 1.
prefix_padding_ms
integer
A duration encoded as an integer number of milliseconds.
silence_duration_ms
integer
A duration encoded as an integer number of milliseconds.
idle_timeout_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
remove_filler_words
boolean
Whether filler words are removed from transcription.
create_response
boolean
Whether a response is created automatically when speech stops.
interrupt_response
boolean
Whether user speech may interrupt the agent's response.
languages
string[]
BCP-47 language codes used for speech detection.
semantic_vad
VoiceAgentSemanticVadTurnDetection
OpenAI semantic VAD turn-detection settings.
eagerness
enum
type
enum
обязательно
echo_cancellation
VoiceAgentEchoCancellation | null
Optional server-side echo cancellation settings.
type
enum
обязательно
The echo cancellation implementation. Always server_echo_cancellation.
reference_source
enum
The source of reference audio used for echo cancellation.
channels
integer
The number of input channels. Use two interleaved channels when reference_source is client.
transcription
VoiceAgentInputTranscription | null
Asynchronous input-audio transcription. Set to null to disable transcription.
language
string
The language of the input audio. Supplying the input language in ISO-639-1 (e.g. en) format will improve accuracy and latency.
languages
string[]
Possible languages of the input audio, in ISO-639-1 format. Supported by gpt-transcribe and gpt-live-transcribe.
keywords
string[]
Words or phrases to guide transcription of the input audio. Supported by gpt-transcribe and gpt-live-transcribe.
prompt
string
An optional text to guide the model's style or continue a previous audio segment. For whisper-1, the prompt is a list of keywords. For gpt-4o-transcribe models (excluding gpt-4o-transcribe-diarize), the prompt is a free text string, for example "expect words related to technology". Prompt is not supported with gpt-realtime-whisper in GA Realtime sessions.
delay
enum
Controls how long the model waits before emitting transcription text. Higher values can improve transcription accuracy at the cost of latency. Only supported with gpt-realtime-whisper in GA Realtime sessions.
model
string | enum
обязательно
The input-audio transcription model identifier. This is a model name, not a Foundry deployment name. Mirrors the transcription models supported by the managed voice backend, covering the OpenAI Realtime transcription models plus the Azure and MAI models. Additional values may be added over time.
enum
custom_speech
object
Optional customer custom speech deployment configuration, keyed by locale.
phrase_list
string[]
Optional phrase hints that bias recognition toward domain terms.
output
VoiceAgentAudioOutputConfig
Output audio configuration for a voice agent. Provider-specific fields are selected by voice_type: - openai: voice and speed. - azure-standard: voice, voice_locale, speed, voice_temperature, custom_lexicon_url, custom_text_normalization_url, prefer_locales, style, pitch, and volume. - azure-custom: all azure-standard fields except style, plus custom_voice_endpoint_id. - azure-personal: all azure-standard fields except style, plus personal_voice_model. - avatar-voice-sync: all azure-standard fields except voice and style, plus personal_voice_model; the voice name is derived from the avatar. - azure-realtime-native: voice and speed. format and output_audio_timestamp_types apply to every voice type.
format
audio/pcm | audio/pcmu | audio/pcma
audio/pcm
OpenAI.RealtimeAudioFormatsAudioPcm
type
enum
обязательно
rate
enum
audio/pcmu
OpenAI.RealtimeAudioFormatsAudioPcmu
type
enum
обязательно
audio/pcma
OpenAI.RealtimeAudioFormatsAudioPcma
type
enum
обязательно
voice
string
The voice name or identifier. Applies to openai, azure-standard, azure-custom, azure-personal, and azure-realtime-native. It does not apply to avatar-voice-sync, which derives the voice name from the avatar.
voice_type
string | enum
The voice implementation. Additional values may be added over time.
enum
voice_locale
string
The enforced BCP-47 output locale. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
speed
number
The numeric output speed multiplier. Applies to all known voice_type values and defaults to 1.
voice_temperature
number
The voice variation temperature. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
custom_lexicon_url
string
The URL of a custom pronunciation lexicon. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
custom_text_normalization_url
string
The URL of a custom text-normalization configuration. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
prefer_locales
string[]
Preferred BCP-47 locales for multilingual synthesis. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
style
string
The voice speaking style. Applies only when voice_type is azure-standard.
pitch
string
The voice pitch adjustment. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
volume
string
The voice volume adjustment. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
custom_voice_endpoint_id
string
The Azure custom-voice deployment endpoint identifier. Applies only when voice_type is azure-custom.
personal_voice_model
string
The Azure personal or avatar voice model. Applies only when voice_type is azure-personal or avatar-voice-sync.
output_audio_timestamp_types
enum[]
Timestamp kinds to include with output audio. Applies to every voice_type.
output_modalities
VoiceOutputModality[]
The output modalities the agent produces. Defaults to ["audio"]. animation and avatar are available when an avatar is configured.
max_output_tokens
integer | enum
The maximum output-token count or the literal inf.
enum
include
enum[]
Additional fields to include in service outputs.
interim_response
static_interim_response | llm_interim_response
Fields shared by interim-response configurations.
static_interim_response
VoiceAgentStaticInterimResponseConfig
A static interim response selected from configured text.
type
enum
обязательно
texts
string[]
Candidate text values for the interim response.
llm_interim_response
VoiceAgentLlmInterimResponseConfig
An interim response generated by a language model.
type
enum
обязательно
model
string
The model used to generate interim responses.
instructions
string
Optional instructions for generating interim responses.
max_completion_tokens
integer
The maximum completion-token count for an interim response.
avatar
VoiceAgentAvatarConfig
Avatar configuration for a voice agent. These values are session defaults and may be overridden when connecting.
type
string | enum
обязательно
The avatar type.
enum
character
string
обязательно
The avatar character identifier, e.g. 'lisa'.
style
string
The avatar style, e.g. 'casual-sitting'.
customized
boolean
Whether the avatar is a customer-customized avatar. Defaults to false.
output_protocol
string | enum
The transport used to deliver the avatar video stream.
enum
model
string
The avatar model identifier.
video
VoiceAgentAvatarVideoParams
Avatar video encoder and presentation settings.
bitrate
integer
The target video bitrate in bits per second.
crop
VoiceAgentAvatarVideoCrop
The rectangular crop applied to avatar video.
resolution
VoiceAgentAvatarVideoResolution
The avatar video resolution.
background
VoiceAgentAvatarVideoBackground
The avatar video background.
scene
VoiceAgentAvatarScene
Avatar placement and motion settings.
output_audit_audio
boolean
Whether audit audio is emitted with avatar output. Defaults to false.
tools
VoiceAgentTool[]
The tools the voice agent may use. Supported tool kinds are function (executed by the client), mcp, system (service-managed session controls), and toolbox. Server-side tools such as web_search, azure_ai_search, and openapi are provided through a toolbox rather than declared directly.
tool_choice
enum | OpenAI.ToolChoiceFunction | OpenAI.ToolChoiceMCP
Tool-selection behavior for a voice agent.
enum
type
enum
обязательно
For function calling, the type is always function.
name
string
обязательно
The name of the function to call.
type
enum
обязательно
For MCP tools, the type is always mcp.
server_label
string
обязательно
The label of the MCP server to use.
parallel_tool_calls
boolean
Whether the model may call multiple tools in parallel.
structured_inputs
object
Set of structured inputs that participate in prompt template substitution, rendered per session before the live session starts.
[key: string]
StructuredInputDefinition
An structured input that can participate in prompt template substitutions and tool argument binding.
description
string
A human-readable description of the input.
default_value
StructuredInputDefinition
The default value for the input if no run-time value is provided.
schema
object
The JSON schema for the structured input (optional).
required
boolean
Whether the input property is required when the agent is invoked. The service defaults to false if a value is not specified by the caller.
subagent_config
VoiceAgentSubagentConfig
Configuration for sibling Foundry text agents that a voice agent may consult.
subagents
VoiceAgentSubagent[]
обязательно
The sibling Foundry text agents, in the same project, that this voice agent may consult.
store
boolean
Whether conversations with this agent are persisted. A single, all-or-nothing persistence switch that defaults to false (privacy-safe: off by default). When true, Foundry persists the full conversation — the transcript/event timeline and raw audio. When false, nothing is persisted and no conversation is surfaced. There is no separate audio-logging control; audio is persisted only as part of this switch. Latency/performance telemetry (e.g. time-to-first-audio, inter-token latency, interruption) is observability-only (customer trace / App Insights) and is not part of the persisted conversation content.
blueprint_reference
ManagedAgentIdentityBlueprint
ManagedAgentIdentityBlueprint
ManagedAgentIdentityBlueprintReference
type
enum
обязательно
blueprint_id
string
обязательно
The ID of the managed blueprint
digital_worker_type
string | enum
The type of digital worker.
enum
draft
boolean
(Preview) Whether this agent version is a draft (candidate) rather than a release. The service defaults to false if a value is not specified by the caller. Draft versions are recorded but excluded from default 'latest' resolution and are not auto-promoted.
agent_endpoint
AgentEndpointConfig
version_selector
VersionSelector
protocol_configuration
ProtocolConfiguration
Per-protocol configuration for the agent endpoint.
activity
ActivityProtocolConfiguration
Configuration specific to the activity protocol.
enable_m365_public_endpoint
boolean
Whether to enable the M365 public endpoint for the activity protocol.
access_boundaries
ActivityProtocolAccessBoundary[]
The access boundaries for the activity protocol.
responses
ResponsesProtocolConfiguration
Configuration specific to the responses protocol.
a2a
A2AProtocolConfiguration
Configuration specific to the A2A protocol.
mcp
McpProtocolConfiguration
Configuration specific to the MCP protocol.
invocations
InvocationsProtocolConfiguration
Configuration specific to the invocations protocol.
invocations_ws
InvocationsWsProtocolConfiguration
Configuration specific to the WebSocket-based invocations protocol.
authorization_schemes
AgentEndpointAuthorizationScheme[]
The authorization schemes supported by the agent endpoint
publish_approval_status
string | enum
The Microsoft Agent Certification review status of the Microsoft 365 store title published for an agent.
enum
agent_card
AgentCard
version
string
обязательно
The version of the agent card.
description
string
The description of the agent card.
skills
AgentCardSkill[]
обязательно
The set of skills that an agent can perform.
metadata
CreateAgentFromCodeContent
обязательно
JSON metadata including description and hosted definition.
code
CreateAgentFromCodeContent
обязательно
The code zip file (max 250 MB).
Ответы
The request has succeeded.
Текст
object
enum
обязательно
The object type, which is always 'agent'.
id
string
обязательно
The unique identifier of the agent.
name
string
обязательно
The name of the agent.
state
string | enum
обязательно
The operational state of an agent.
enum
configuration_state
string | enum
обязательно
The operational state of an agent.
enum
state_source
string | enum
Indicates the source of an agent's operational state. Empty when the state is not derived from a specific source.
enum
versions
AgentObject
обязательно
The latest version of the agent.
latest
AgentVersionObject
обязательно
metadata
object | null
обязательно
Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format, and querying for objects via API or the dashboard. Keys are strings with a maximum length of 64 characters. Values are strings with a maximum length of 512 characters.
object
enum
обязательно
The object type, which is always 'agent.version'.
id
string
обязательно
The unique identifier of the agent version.
name
string
обязательно
The name of the agent. Name can be used to retrieve/update/delete the agent.
version
string
обязательно
The version identifier of the agent. Agents are immutable and every update creates a new version while keeping the name same.
description
string
A human-readable description of the agent.
definition
hosted | prompt | workflow | external | voice
обязательно
hosted
HostedAgentDefinition
The hosted agent definition.
kind
enum
обязательно
cpu
string
обязательно
The CPU configuration for the hosted agent.
memory
string
обязательно
The memory configuration for the hosted agent.
environment_variables
object
Environment variables to set in the hosted agent container.
container_configuration
ContainerConfiguration
Container-based deployment configuration for a hosted agent.
image
string
обязательно
The container image for the hosted agent.
registry_connection_id
string
The id (or name) of the Foundry project connection that provides the credentials used to authenticate to the private container registry hosting image. The connection abstracts the auth mechanism — for example a managed-identity-federated token exchange, or a username/token secret — so registry credentials are never part of the agent definition. Omit for public images or registries already reachable by the platform's default identity (for example, Azure Container Registry).
protocol_versions
ProtocolVersionRecord[]
The protocols that the agent supports for ingress communication.
code_configuration
CodeConfiguration
Code-based deployment configuration for a hosted agent.
runtime
string
обязательно
The runtime identifier for code execution (e.g., 'python_3_11', 'python_3_12', 'python_3_13').
entry_point
string[]
обязательно
The entry point command and arguments for the code execution.
dependency_resolution
string | enum
обязательно
How package dependencies are resolved at deployment time for a code-based hosted agent.
enum
content_hash
string
The SHA-256 hex digest of the uploaded code zip. Set by the service from the x-ms-code-zip-sha256 request header; read-only in responses and never accepted in request payloads.
telemetry_config
TelemetryConfig
Customer-supplied telemetry configuration for exporting container logs, traces, and metrics.
endpoints
TelemetryEndpoint[]
обязательно
Customer-supplied telemetry export endpoint configurations.
session_configuration
SessionConfiguration
Session defaults applied to sessions created for a hosted agent version.
idle_timeout_seconds
integer
The idle duration, in seconds, before a session's sandbox is suspended. Optional — when unset, the server default of 900 seconds is used. Must be between 120 and 3600 seconds (inclusive).
prompt
PromptAgentDefinition
The prompt agent definition
kind
enum
обязательно
harness
github_copilot_preview
A managed runtime and agent loop used to execute a prompt agent.
github_copilot_preview
GitHubCopilotHarness
The GitHub Copilot managed harness for prompt agents.
type
enum
обязательно
The type of managed harness. Always github_copilot_preview.
model
string
обязательно
The model deployment to use for this agent.
instructions
string | null
A system (or developer) message inserted into the model's context.
skills
SkillReference[]
The Foundry skills available to this prompt agent. An omitted skill version is resolved and pinned when the agent version is created.
temperature
number | null
What sampling temperature to use, between 0 and 2. Higher values like 0.8 will make the output more random, while lower values like 0.2 will make it more focused and deterministic. We generally recommend altering this or top_p but not both. Defaults to 1.
top_p
number | null
An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered. We generally recommend altering this or temperature but not both. Defaults to 1.
reasoning
OpenAI.Reasoning | null
Configuration options for reasoning models.
mode
string | enum
enum
effort
string | enum | null
Constrains effort on reasoning for reasoning models. Currently supported values are none, minimal, low, medium, high, xhigh, and max. Reducing reasoning effort can result in faster responses and fewer tokens used on reasoning in a response. Not all reasoning models support every value. See the reasoning guide for model-specific support.
enum
summary
enum
context
enum
generate_summary
enum
tools
OpenAI.Tool[]
An array of tools the model may call while generating a response. You can specify which tool to use by setting the tool_choice parameter.
tool_choice
string | OpenAI.ToolChoiceParam
How the model should select which tool (or tools) to use when generating a response. See the tools parameter to see how to specify which tools the model can call.
function
OpenAI.ToolChoiceFunction
Use this option to force the model to call a specific function.
type
enum
обязательно
For function calling, the type is always function.
name
string
обязательно
The name of the function to call.
mcp
OpenAI.ToolChoiceMCP
Use this option to force the model to call a specific tool on a remote MCP server.
type
enum
обязательно
For MCP tools, the type is always mcp.
server_label
string
обязательно
The label of the MCP server to use.
allowed_tools
OpenAI.ToolChoiceAllowed
Constrains the tools available to the model to a pre-defined set.
type
enum
обязательно
Allowed tool configuration type. Always allowed_tools.
mode
enum
обязательно
Constrains the tools available to the model to a pre-defined set. auto allows the model to pick from among the allowed tools and generate a message. required requires the model to call one or more of the allowed tools.
tools
object[]
обязательно
A list of tool definitions that the model should be allowed to call. For the Responses API, the list of tool definitions might look like: json [ { "type": "function", "name": "get_weather" }, { "type": "mcp", "server_label": "deepwiki" }, { "type": "image_generation" } ]
custom
OpenAI.ToolChoiceCustom
Use this option to force the model to call a specific custom tool.
type
enum
обязательно
For custom tool calling, the type is always custom.
name
string
обязательно
The name of the custom tool to call.
programmatic_tool_calling
OpenAI.SpecificProgrammaticToolCallingParam
type
enum
обязательно
The tool to call. Always programmatic_tool_calling.
apply_patch
OpenAI.SpecificApplyPatchParam
Forces the model to call the apply_patch tool when executing a tool call.
type
enum
обязательно
The tool to call. Always apply_patch.
shell
OpenAI.SpecificFunctionShellParam
Forces the model to call the shell tool when a tool call is required.
type
enum
обязательно
The tool to call. Always shell.
file_search
OpenAI.ToolChoiceFileSearch
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
web_search_preview
OpenAI.ToolChoiceWebSearchPreview
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
computer_use_preview
OpenAI.ToolChoiceComputerUsePreview
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
web_search_preview_2025_03_11
OpenAI.ToolChoiceWebSearchPreview20250311
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
image_generation
OpenAI.ToolChoiceImageGeneration
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
code_interpreter
OpenAI.ToolChoiceCodeInterpreter
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
computer
OpenAI.ToolChoiceComputer
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
computer_use
OpenAI.ToolChoiceComputerUse
Indicates that the model should use a built-in tool to generate a response. Learn more about built-in tools.
type
enum
обязательно
text
PromptAgentDefinitionTextOptions
Configuration options for a text response from the model. Can be plain text or structured JSON data.
format
json_schema | text | json_object
An object specifying the format that the model must output. Configuring { "type": "json_schema" } enables Structured Outputs, which ensures the model will match your supplied JSON schema. Learn more in the Structured Outputs guide. The default format is { "type": "text" } with no additional options. Not recommended for gpt-4o and newer models:* Setting to { "type": "json_object" } enables the older JSON mode, which ensures the message the model generates is valid JSON. Using json_schema is preferred for models that support it.
json_schema
OpenAI.TextResponseFormatJsonSchema
JSON Schema response format. Used to generate structured JSON responses. Learn more about Structured Outputs.
type
enum
обязательно
The type of response format being defined. Always json_schema.
description
string
A description of what the response format is for, used by the model to determine how to respond in the format.
name
string
обязательно
The name of the response format. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
schema
OpenAI.ResponseFormatJsonSchemaSchema
обязательно
The schema for the response format, described as a JSON Schema object. Learn how to build JSON schemas here.
text
OpenAI.TextResponseFormatConfigurationResponseFormatText
Default response format. Used to generate text responses.
type
enum
обязательно
The type of response format being defined. Always text.
json_object
OpenAI.TextResponseFormatConfigurationResponseFormatJsonObject
JSON object response format. An older method of generating JSON responses. Using json_schema is recommended for models that support it. Note that the model will not generate JSON without a system or user message instructing it to do so.
type
enum
обязательно
The type of response format being defined. Always json_object.
structured_inputs
object
Set of structured inputs that can participate in prompt template substitution or tool argument bindings.
[key: string]
StructuredInputDefinition
An structured input that can participate in prompt template substitutions and tool argument binding.
description
string
A human-readable description of the input.
default_value
StructuredInputDefinition
The default value for the input if no run-time value is provided.
schema
object
The JSON schema for the structured input (optional).
required
boolean
Whether the input property is required when the agent is invoked. The service defaults to false if a value is not specified by the caller.
workflow
WorkflowAgentDefinition
The workflow agent definition. Microsoft Foundry is retiring workflows on December 1, 2026. If you're looking to build new workflows, use Microsoft Agent Framework. To migrate existing workflows, see the Migration guide.
kind
enum
обязательно
workflow
string
The CSDL YAML definition of the workflow.
external
ExternalAgentDefinition
The external agent definition. Represents a third-party agent hosted outside Foundry (for example, on GCP or AWS). Registration is metadata-only: Foundry records the agent definition to light up observability experiences (traces, evaluations) over customer-emitted OpenTelemetry data.
kind
enum
обязательно
otel_agent_id
string
The OpenTelemetry agent identifier used to attribute customer-emitted spans to this Foundry agent. Spans must include the attribute gen_ai.agent.id = <otel_agent_id> to appear under this registration. Defaults to the top-level agent name when omitted. Provide an explicit value only for migration scenarios where the running external agent already emits a stable id that differs from the Foundry agent name. The resolved value is always echoed on read.
voice
VoiceAgentDefinition
The voice agent definition. Its configuration (model, instructions, audio, tools, and optional avatar) drives a managed speech-to-speech experience. Establish realtime voice sessions through GET /agents/{agent_name}/endpoint/protocols/voice. Every create or update produces a new immutable version.
kind
enum
обязательно
The kind discriminator for a voice agent definition. Always voice.
model_type
string | enum
How the model backing a voice agent is served. This is independent of the architecture (realtime or cascaded), which the service derives from the selected model.
enum
model
string
The model to use for this agent. Required with model_type for a model-backed voice agent and omitted when conversation_engine is provided. The model must support realtime or cascaded voice.
conversation_engine
hosted_agent
An engine that owns conversation handling for a voice agent.
hosted_agent
VoiceHostedAgentConversationEngine
A closed reference to the hosted text agent that owns conversation handling for a voice agent. The hosted agent is resolved within the same project and must support the invocations_ws protocol, Voice Live compatibility, and Bridge Protocol 1.0.
type
enum
обязательно
Selects a hosted Foundry agent as the conversation engine.
name
string
обязательно
The non-empty DNS-like name of the target hosted text agent in the same project.
version
string
The target agent version. Omit this property to select the latest version when the voice session starts. When supplied, use a positive integer or draft-{positive-unix-timestamp} whose numeric component fits in a signed 64-bit integer.
instructions
string
A system (or developer) message inserted into the model's context. Supports template substitution via structured_inputs, rendered per session before the live session starts.
greeting
template | llm_generated
Session-start greeting configuration for a voice agent.
template
VoiceAgentTemplateGreetingConfig
A deterministic greeting rendered with the voice agent's structured inputs and synthesized without model-authored generation.
type
enum
обязательно
text
string
обязательно
The Handlebars text template spoken at session start.
llm_generated
VoiceAgentLlmGeneratedGreetingConfig
A greeting authored by the session model from a scoped opening-turn prompt.
type
enum
обязательно
prompt
string
обязательно
The Handlebars prompt that guides the opening turn.
tool_choice
enum | OpenAI.ToolChoiceFunction | OpenAI.ToolChoiceMCP
Tool-selection behavior for a voice agent.
enum
type
enum
обязательно
For function calling, the type is always function.
name
string
обязательно
The name of the function to call.
type
enum
обязательно
For MCP tools, the type is always mcp.
server_label
string
обязательно
The label of the MCP server to use.
audio
VoiceAgentAudioConfig
The audio configuration for a voice agent. These values are session defaults and may be overridden when connecting.
input
VoiceAgentAudioInputConfig
Input audio configuration for a voice agent.
format
audio/pcm | audio/pcmu | audio/pcma
audio/pcm
OpenAI.RealtimeAudioFormatsAudioPcm
type
enum
обязательно
rate
enum
audio/pcmu
OpenAI.RealtimeAudioFormatsAudioPcmu
type
enum
обязательно
audio/pcma
OpenAI.RealtimeAudioFormatsAudioPcma
type
enum
обязательно
noise_reduction
VoiceAgentNoiseReduction | null
Input noise reduction. Set to null to disable.
type
string | enum
обязательно
The input audio noise reduction mode.
enum
turn_detection
server_vad | azure_semantic_vad | azure_semantic_vad_en | azure_semantic_vad_multilingual | semantic_vad | null
Turn (end-of-speech) detection. Server-side turn detection is enabled by default; set to null to disable it, in which case the client must trigger responses manually.
server_vad
VoiceAgentServerVadTurnDetection
Server-side voice activity detection.
type
enum
обязательно
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
azure_semantic_vad
VoiceAgentAzureSemanticVadTurnDetection
Azure semantic voice activity detection.
type
enum
обязательно
threshold
number
Activation threshold for voice activity detection, from 0 to 1.
prefix_padding_ms
integer
A duration encoded as an integer number of milliseconds.
silence_duration_ms
integer
A duration encoded as an integer number of milliseconds.
idle_timeout_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
remove_filler_words
boolean
Whether filler words are removed from transcription.
create_response
boolean
Whether a response is created automatically when speech stops.
interrupt_response
boolean
Whether user speech may interrupt the agent's response.
languages
string[]
BCP-47 language codes used for speech detection.
azure_semantic_vad_en
VoiceAgentAzureSemanticVadEnTurnDetection
English-optimized Azure semantic voice activity detection.
type
enum
обязательно
threshold
number
Activation threshold for voice activity detection, from 0 to 1.
prefix_padding_ms
integer
A duration encoded as an integer number of milliseconds.
silence_duration_ms
integer
A duration encoded as an integer number of milliseconds.
idle_timeout_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
remove_filler_words
boolean
Whether filler words are removed from transcription.
create_response
boolean
Whether a response is created automatically when speech stops.
interrupt_response
boolean
Whether user speech may interrupt the agent's response.
azure_semantic_vad_multilingual
VoiceAgentAzureSemanticVadMultilingualTurnDetection
Multilingual Azure semantic voice activity detection.
type
enum
обязательно
threshold
number
Activation threshold for voice activity detection, from 0 to 1.
prefix_padding_ms
integer
A duration encoded as an integer number of milliseconds.
silence_duration_ms
integer
A duration encoded as an integer number of milliseconds.
idle_timeout_ms
integer
A duration encoded as an integer number of milliseconds.
end_of_utterance_detection
VoiceAgentEndOfUtteranceDetection | null
Semantic end-of-utterance detection configuration. Set to null to disable it.
model
string | enum
обязательно
The semantic end-of-utterance detection model.
enum
threshold_level
string | enum
The sensitivity threshold for semantic end-of-utterance detection.
enum
timeout_ms
integer
A duration encoded as an integer number of milliseconds.
speech_duration_ms
integer
A duration encoded as an integer number of milliseconds.
remove_filler_words
boolean
Whether filler words are removed from transcription.
create_response
boolean
Whether a response is created automatically when speech stops.
interrupt_response
boolean
Whether user speech may interrupt the agent's response.
languages
string[]
BCP-47 language codes used for speech detection.
semantic_vad
VoiceAgentSemanticVadTurnDetection
OpenAI semantic VAD turn-detection settings.
eagerness
enum
type
enum
обязательно
echo_cancellation
VoiceAgentEchoCancellation | null
Optional server-side echo cancellation settings.
type
enum
обязательно
The echo cancellation implementation. Always server_echo_cancellation.
reference_source
enum
The source of reference audio used for echo cancellation.
channels
integer
The number of input channels. Use two interleaved channels when reference_source is client.
transcription
VoiceAgentInputTranscription | null
Asynchronous input-audio transcription. Set to null to disable transcription.
language
string
The language of the input audio. Supplying the input language in ISO-639-1 (e.g. en) format will improve accuracy and latency.
languages
string[]
Possible languages of the input audio, in ISO-639-1 format. Supported by gpt-transcribe and gpt-live-transcribe.
keywords
string[]
Words or phrases to guide transcription of the input audio. Supported by gpt-transcribe and gpt-live-transcribe.
prompt
string
An optional text to guide the model's style or continue a previous audio segment. For whisper-1, the prompt is a list of keywords. For gpt-4o-transcribe models (excluding gpt-4o-transcribe-diarize), the prompt is a free text string, for example "expect words related to technology". Prompt is not supported with gpt-realtime-whisper in GA Realtime sessions.
delay
enum
Controls how long the model waits before emitting transcription text. Higher values can improve transcription accuracy at the cost of latency. Only supported with gpt-realtime-whisper in GA Realtime sessions.
model
string | enum
обязательно
The input-audio transcription model identifier. This is a model name, not a Foundry deployment name. Mirrors the transcription models supported by the managed voice backend, covering the OpenAI Realtime transcription models plus the Azure and MAI models. Additional values may be added over time.
enum
custom_speech
object
Optional customer custom speech deployment configuration, keyed by locale.
phrase_list
string[]
Optional phrase hints that bias recognition toward domain terms.
output
VoiceAgentAudioOutputConfig
Output audio configuration for a voice agent. Provider-specific fields are selected by voice_type: - openai: voice and speed. - azure-standard: voice, voice_locale, speed, voice_temperature, custom_lexicon_url, custom_text_normalization_url, prefer_locales, style, pitch, and volume. - azure-custom: all azure-standard fields except style, plus custom_voice_endpoint_id. - azure-personal: all azure-standard fields except style, plus personal_voice_model. - avatar-voice-sync: all azure-standard fields except voice and style, plus personal_voice_model; the voice name is derived from the avatar. - azure-realtime-native: voice and speed. format and output_audio_timestamp_types apply to every voice type.
format
audio/pcm | audio/pcmu | audio/pcma
audio/pcm
OpenAI.RealtimeAudioFormatsAudioPcm
type
enum
обязательно
rate
enum
audio/pcmu
OpenAI.RealtimeAudioFormatsAudioPcmu
type
enum
обязательно
audio/pcma
OpenAI.RealtimeAudioFormatsAudioPcma
type
enum
обязательно
voice
string
The voice name or identifier. Applies to openai, azure-standard, azure-custom, azure-personal, and azure-realtime-native. It does not apply to avatar-voice-sync, which derives the voice name from the avatar.
voice_type
string | enum
The voice implementation. Additional values may be added over time.
enum
voice_locale
string
The enforced BCP-47 output locale. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
speed
number
The numeric output speed multiplier. Applies to all known voice_type values and defaults to 1.
voice_temperature
number
The voice variation temperature. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
custom_lexicon_url
string
The URL of a custom pronunciation lexicon. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
custom_text_normalization_url
string
The URL of a custom text-normalization configuration. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
prefer_locales
string[]
Preferred BCP-47 locales for multilingual synthesis. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
style
string
The voice speaking style. Applies only when voice_type is azure-standard.
pitch
string
The voice pitch adjustment. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
volume
string
The voice volume adjustment. Applies to azure-standard, azure-custom, azure-personal, and avatar-voice-sync.
custom_voice_endpoint_id
string
The Azure custom-voice deployment endpoint identifier. Applies only when voice_type is azure-custom.
personal_voice_model
string
The Azure personal or avatar voice model. Applies only when voice_type is azure-personal or avatar-voice-sync.
output_audio_timestamp_types
enum[]
Timestamp kinds to include with output audio. Applies to every voice_type.
output_modalities
VoiceOutputModality[]
The output modalities the agent produces. Defaults to ["audio"]. animation and avatar are available when an avatar is configured.
max_output_tokens
integer | enum
The maximum output-token count or the literal inf.
enum
include
enum[]
Additional fields to include in service outputs.
interim_response
static_interim_response | llm_interim_response
Fields shared by interim-response configurations.
static_interim_response
VoiceAgentStaticInterimResponseConfig
A static interim response selected from configured text.
type
enum
обязательно
texts
string[]
Candidate text values for the interim response.
llm_interim_response
VoiceAgentLlmInterimResponseConfig
An interim response generated by a language model.
type
enum
обязательно
model
string
The model used to generate interim responses.
instructions
string
Optional instructions for generating interim responses.
max_completion_tokens
integer
The maximum completion-token count for an interim response.
avatar
VoiceAgentAvatarConfig
Avatar configuration for a voice agent. These values are session defaults and may be overridden when connecting.
type
string | enum
обязательно
The avatar type.
enum
character
string
обязательно
The avatar character identifier, e.g. 'lisa'.
style
string
The avatar style, e.g. 'casual-sitting'.
customized
boolean
Whether the avatar is a customer-customized avatar. Defaults to false.
output_protocol
string | enum
The transport used to deliver the avatar video stream.
enum
model
string
The avatar model identifier.
video
VoiceAgentAvatarVideoParams
Avatar video encoder and presentation settings.
bitrate
integer
The target video bitrate in bits per second.
crop
VoiceAgentAvatarVideoCrop
The rectangular crop applied to avatar video.
resolution
VoiceAgentAvatarVideoResolution
The avatar video resolution.
background
VoiceAgentAvatarVideoBackground
The avatar video background.
scene
VoiceAgentAvatarScene
Avatar placement and motion settings.
output_audit_audio
boolean
Whether audit audio is emitted with avatar output. Defaults to false.
tools
VoiceAgentTool[]
The tools the voice agent may use. Supported tool kinds are function (executed by the client), mcp, system (service-managed session controls), and toolbox. Server-side tools such as web_search, azure_ai_search, and openapi are provided through a toolbox rather than declared directly.
tool_choice
enum | OpenAI.ToolChoiceFunction | OpenAI.ToolChoiceMCP
Tool-selection behavior for a voice agent.
enum
type
enum
обязательно
For function calling, the type is always function.
name
string
обязательно
The name of the function to call.
type
enum
обязательно
For MCP tools, the type is always mcp.
server_label
string
обязательно
The label of the MCP server to use.
parallel_tool_calls
boolean
Whether the model may call multiple tools in parallel.
structured_inputs
object
Set of structured inputs that participate in prompt template substitution, rendered per session before the live session starts.
[key: string]
StructuredInputDefinition
An structured input that can participate in prompt template substitutions and tool argument binding.
description
string
A human-readable description of the input.
default_value
StructuredInputDefinition
The default value for the input if no run-time value is provided.
schema
object
The JSON schema for the structured input (optional).
required
boolean
Whether the input property is required when the agent is invoked. The service defaults to false if a value is not specified by the caller.
subagent_config
VoiceAgentSubagentConfig
Configuration for sibling Foundry text agents that a voice agent may consult.
subagents
VoiceAgentSubagent[]
обязательно
The sibling Foundry text agents, in the same project, that this voice agent may consult.
store
boolean
Whether conversations with this agent are persisted. A single, all-or-nothing persistence switch that defaults to false (privacy-safe: off by default). When true, Foundry persists the full conversation — the transcript/event timeline and raw audio. When false, nothing is persisted and no conversation is surfaced. There is no separate audio-logging control; audio is persisted only as part of this switch. Latency/performance telemetry (e.g. time-to-first-audio, inter-token latency, interruption) is observability-only (customer trace / App Insights) and is not part of the persisted conversation content.
draft
boolean
Whether this agent version is a draft (candidate) rather than a release. Draft versions are recorded but excluded from default 'latest' resolution and are not auto-promoted. Defaults to false.
status
enum
The provisioning status of an agent version.
instance_identity
AgentIdentity
principal_id
string
обязательно
The principal ID of the agent instance
client_id
string
обязательно
The client ID of the agent instance. Also referred to as the instance ID
status
string | enum
The status of an agent identity, applicable to both the agent instance identity and the agent blueprint.
enum
blueprint
AgentIdentity
principal_id
string
обязательно
The principal ID of the agent instance
client_id
string
обязательно
The client ID of the agent instance. Also referred to as the instance ID
status
string | enum
The status of an agent identity, applicable to both the agent instance identity and the agent blueprint.
enum
blueprint_reference
ManagedAgentIdentityBlueprint
ManagedAgentIdentityBlueprint
ManagedAgentIdentityBlueprintReference
type
enum
обязательно
blueprint_id
string
обязательно
The ID of the managed blueprint
agent_guid
string
The unique GUID identifier of the agent.
agent_endpoint
AgentEndpointConfig
version_selector
VersionSelector
protocol_configuration
ProtocolConfiguration
Per-protocol configuration for the agent endpoint.
activity
ActivityProtocolConfiguration
Configuration specific to the activity protocol.
enable_m365_public_endpoint
boolean
Whether to enable the M365 public endpoint for the activity protocol.
access_boundaries
ActivityProtocolAccessBoundary[]
The access boundaries for the activity protocol.
responses
ResponsesProtocolConfiguration
Configuration specific to the responses protocol.
a2a
A2AProtocolConfiguration
Configuration specific to the A2A protocol.
mcp
McpProtocolConfiguration
Configuration specific to the MCP protocol.
invocations
InvocationsProtocolConfiguration
Configuration specific to the invocations protocol.
invocations_ws
InvocationsWsProtocolConfiguration
Configuration specific to the WebSocket-based invocations protocol.
authorization_schemes
AgentEndpointAuthorizationScheme[]
The authorization schemes supported by the agent endpoint
publish_approval_status
string | enum
The Microsoft Agent Certification review status of the Microsoft 365 store title published for an agent.
enum
digital_worker_type
string | enum
The type of digital worker.
enum
instance_identity
AgentIdentity
principal_id
string
обязательно
The principal ID of the agent instance
client_id
string
обязательно
The client ID of the agent instance. Also referred to as the instance ID
status
string | enum
The status of an agent identity, applicable to both the agent instance identity and the agent blueprint.
enum
blueprint
AgentIdentity
principal_id
string
обязательно
The principal ID of the agent instance
client_id
string
обязательно
The client ID of the agent instance. Also referred to as the instance ID
status
string | enum
The status of an agent identity, applicable to both the agent instance identity and the agent blueprint.
enum
blueprint_reference
ManagedAgentIdentityBlueprint
ManagedAgentIdentityBlueprint
ManagedAgentIdentityBlueprintReference
type
enum
обязательно
blueprint_id
string
обязательно
The ID of the managed blueprint
agent_card
AgentCard
version
string
обязательно
The version of the agent card.
description
string
The description of the agent card.
skills
AgentCardSkill[]
обязательно
The set of skills that an agent can perform.
Запрос
POST /agents HTTP/1.1
Response
Status: 200
Content-Type: application/json
Status: 4XX
Content-Type: application/json
Status: 5XX
Content-Type: application/json