Language

ModelDeploymentCollection.CreateOrUpdateAsync Method

Definition

Create or update a ModelDeployment. This is a full-replace operation: any optional property omitted from the request body is reset to its default value, or cleared if it has no default. To safely modify a subset of fields, perform a GET, modify the returned resource, and PUT it back using the returned ETag via the If-Match header to avoid concurrent overwrites.

  • Request Path. : /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ContainerService/aiManagers/{aiManagerName}/namespaces/{namespaceName}/modelDeployments/{modelDeploymentName}.
  • Operation Id. : ModelDeployments_CreateOrUpdate.
  • Default Api Version. : 2026-09-02-preview.
public virtual System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ContainerServiceAIManager.ModelDeploymentResource>> CreateOrUpdateAsync(Azure.WaitUntil waitUntil, string modelDeploymentName, Azure.ResourceManager.ContainerServiceAIManager.ModelDeploymentData data, Azure.MatchConditions matchConditions = default, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrUpdateAsync : Azure.WaitUntil * string * Azure.ResourceManager.ContainerServiceAIManager.ModelDeploymentData * Azure.MatchConditions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ContainerServiceAIManager.ModelDeploymentResource>>
override this.CreateOrUpdateAsync : Azure.WaitUntil * string * Azure.ResourceManager.ContainerServiceAIManager.ModelDeploymentData * Azure.MatchConditions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ContainerServiceAIManager.ModelDeploymentResource>>
Public Overridable Function CreateOrUpdateAsync (waitUntil As WaitUntil, modelDeploymentName As String, data As ModelDeploymentData, Optional matchConditions As MatchConditions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ArmOperation(Of ModelDeploymentResource))

Parameters

waitUntil
WaitUntil

Completed if the method should wait to return until the long-running operation has completed on the service; Started if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples.

modelDeploymentName
String

The name of the model deployment resource.

data
ModelDeploymentData

Resource create parameters.

matchConditions
MatchConditions

The content to send as the request conditions of the request.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

modelDeploymentName or data is null.

modelDeploymentName is an empty string, and was expected to be non-empty.

Applies to