ResourceGraphQueryCollection.CreateOrUpdate Method

Definition

Create a new graph query.

  • Request Path. : /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ResourceGraph/queries/{resourceName}.
  • Operation Id. : GraphQueryResources_CreateOrUpdate.
  • Default Api Version. : 2024-04-01.
public virtual Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ResourceGraph.ResourceGraphQueryResource> CreateOrUpdate(Azure.WaitUntil waitUntil, string resourceName, Azure.ResourceManager.ResourceGraph.ResourceGraphQueryData data, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.ResourceGraph.ResourceGraphQueryData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ResourceGraph.ResourceGraphQueryResource>
override this.CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.ResourceGraph.ResourceGraphQueryData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.ResourceGraph.ResourceGraphQueryResource>
Public Overridable Function CreateOrUpdate (waitUntil As WaitUntil, resourceName As String, data As ResourceGraphQueryData, Optional cancellationToken As CancellationToken = Nothing) As ArmOperation(Of ResourceGraphQueryResource)

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.

resourceName
String

The name of the Graph Query resource.

data
ResourceGraphQueryData

Properties that need to be specified to create a new graph query.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

resourceName or data is null.

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

Applies to