Share via


SubscriptionExtensions.AcceptSubscriptionOwnershipAsync Method

Definition

Accept subscription ownership.

  • Request Path: /providers/Microsoft.Subscription/subscriptions/{subscriptionId}/acceptOwnership
  • Operation Id: Subscription_AcceptOwnership
public static System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation> AcceptSubscriptionOwnershipAsync (this Azure.ResourceManager.Resources.TenantResource tenantResource, Azure.WaitUntil waitUntil, string subscriptionId, Azure.ResourceManager.Subscription.Models.AcceptOwnershipContent content, System.Threading.CancellationToken cancellationToken = default);
static member AcceptSubscriptionOwnershipAsync : Azure.ResourceManager.Resources.TenantResource * Azure.WaitUntil * string * Azure.ResourceManager.Subscription.Models.AcceptOwnershipContent * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation>
<Extension()>
Public Function AcceptSubscriptionOwnershipAsync (tenantResource As TenantResource, waitUntil As WaitUntil, subscriptionId As String, content As AcceptOwnershipContent, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ArmOperation)

Parameters

tenantResource
TenantResource

The TenantResource instance the method will execute against.

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.

subscriptionId
String

Subscription Id.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

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

tenantResource, subscriptionId or content is null.

Applies to