Share via


SubscriptionAssessmentMetadataCollection.CreateOrUpdate Method

Definition

Create metadata information on an assessment type in a specific subscription

  • Request Path: /subscriptions/{subscriptionId}/providers/Microsoft.Security/assessmentMetadata/{assessmentMetadataName}
  • Operation Id: AssessmentsMetadata_CreateInSubscription
  • Default Api Version: 2021-06-01
  • Resource: SubscriptionAssessmentMetadataResource
public virtual Azure.ResourceManager.ArmOperation<Azure.ResourceManager.SecurityCenter.SubscriptionAssessmentMetadataResource> CreateOrUpdate (Azure.WaitUntil waitUntil, string assessmentMetadataName, Azure.ResourceManager.SecurityCenter.SecurityAssessmentMetadataData data, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.SecurityCenter.SecurityAssessmentMetadataData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.SecurityCenter.SubscriptionAssessmentMetadataResource>
override this.CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.SecurityCenter.SecurityAssessmentMetadataData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.SecurityCenter.SubscriptionAssessmentMetadataResource>
Public Overridable Function CreateOrUpdate (waitUntil As WaitUntil, assessmentMetadataName As String, data As SecurityAssessmentMetadataData, Optional cancellationToken As CancellationToken = Nothing) As ArmOperation(Of SubscriptionAssessmentMetadataResource)

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.

assessmentMetadataName
String

The Assessment Key - Unique key for the assessment type.

data
SecurityAssessmentMetadataData

AssessmentMetadata object.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

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

assessmentMetadataName or data is null.

Applies to