Exemple #1
0
 /// <summary>
 /// Deletes an existing API Management service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <ApiManagementServiceResource> BeginDeleteAsync(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.BeginDeleteWithHttpMessagesAsync(resourceGroupName, serviceName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Upload Custom Domain SSL certificate for an API Management service. This
 /// operation will be deprecated in future releases.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Upload SSL certificate for an API Management
 /// service operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <CertificateInformation> UploadCertificateAsync(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, ApiManagementServiceUploadCertificateParameters parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.UploadCertificateWithHttpMessagesAsync(resourceGroupName, serviceName, parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #3
0
 /// <summary>
 /// Lists all API Management services within an Azure subscription.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <ApiManagementServiceResource> > ListAsync(this IApiManagementServiceOperations operations, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListWithHttpMessagesAsync(null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #4
0
 /// <summary>
 /// Deletes an existing API Management service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 public static ApiManagementServiceResource BeginDelete(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName)
 {
     return(operations.BeginDeleteAsync(resourceGroupName, serviceName).GetAwaiter().GetResult());
 }
Exemple #5
0
 /// <summary>
 /// Creates or updates an API Management service. This is long running
 /// operation and could take several minutes to complete.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the CreateOrUpdate API Management service operation.
 /// </param>
 public static ApiManagementServiceResource BeginCreateOrUpdate(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, ApiManagementServiceResource parameters)
 {
     return(operations.BeginCreateOrUpdateAsync(resourceGroupName, serviceName, parameters).GetAwaiter().GetResult());
 }
Exemple #6
0
 /// <summary>
 /// Checks availability and correctness of a name for an API Management
 /// service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the CheckNameAvailability operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <ApiManagementServiceNameAvailabilityResult> CheckNameAvailabilityAsync(this IApiManagementServiceOperations operations, ApiManagementServiceCheckNameAvailabilityParameters parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CheckNameAvailabilityWithHttpMessagesAsync(parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #7
0
 /// <summary>
 /// Checks availability and correctness of a name for an API Management
 /// service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the CheckNameAvailability operation.
 /// </param>
 public static ApiManagementServiceNameAvailabilityResult CheckNameAvailability(this IApiManagementServiceOperations operations, ApiManagementServiceCheckNameAvailabilityParameters parameters)
 {
     return(operations.CheckNameAvailabilityAsync(parameters).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Get the custom domain ownership identifier for an API Management service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <ApiManagementServiceGetDomainOwnershipIdentifierResult> GetDomainOwnershipIdentifierAsync(this IApiManagementServiceOperations operations, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetDomainOwnershipIdentifierWithHttpMessagesAsync(null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #9
0
 /// <summary>
 /// Lists all API Management services within an Azure subscription.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 public static IPage <ApiManagementServiceResource> ListNext(this IApiManagementServiceOperations operations, string nextPageLink)
 {
     return(operations.ListNextAsync(nextPageLink).GetAwaiter().GetResult());
 }
Exemple #10
0
 /// <summary>
 /// Lists all API Management services within an Azure subscription.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 public static IPage <ApiManagementServiceResource> List(this IApiManagementServiceOperations operations)
 {
     return(operations.ListAsync().GetAwaiter().GetResult());
 }
Exemple #11
0
 /// <summary>
 /// List all API Management services within a resource group.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 public static IPage <ApiManagementServiceResource> ListByResourceGroup(this IApiManagementServiceOperations operations, string resourceGroupName)
 {
     return(operations.ListByResourceGroupAsync(resourceGroupName).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Creates, updates, or deletes the custom hostnames for an API Management
 /// service. The custom hostname can be applied to the Proxy and Portal
 /// endpoint. This is a long running operation and could take several minutes
 /// to complete. This operation will be deprecated in the next version update.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the UpdateHostname operation.
 /// </param>
 public static ApiManagementServiceResource UpdateHostname(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, ApiManagementServiceUpdateHostnameParameters parameters)
 {
     return(operations.UpdateHostnameAsync(resourceGroupName, serviceName, parameters).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Upload Custom Domain SSL certificate for an API Management service. This
 /// operation will be deprecated in future releases.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Upload SSL certificate for an API Management
 /// service operation.
 /// </param>
 public static CertificateInformation UploadCertificate(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, ApiManagementServiceUploadCertificateParameters parameters)
 {
     return(operations.UploadCertificateAsync(resourceGroupName, serviceName, parameters).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Deletes an existing API Management service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task DeleteAsync(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.DeleteWithHttpMessagesAsync(resourceGroupName, serviceName, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
 /// <summary>
 /// Deletes an existing API Management service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 public static void Delete(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName)
 {
     operations.DeleteAsync(resourceGroupName, serviceName).GetAwaiter().GetResult();
 }
Exemple #16
0
 /// <summary>
 /// Updates the Microsoft.ApiManagement resource running in the Virtual network
 /// to pick the updated network settings.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Apply Network Configuration operation. If the
 /// parameters are empty, all the regions in which the Api Management service
 /// is deployed will be updated sequentially without incurring downtime in the
 /// region.
 /// </param>
 public static ApiManagementServiceResource BeginApplyNetworkConfigurationUpdates(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, ApiManagementServiceApplyNetworkConfigurationParameters parameters = default(ApiManagementServiceApplyNetworkConfigurationParameters))
 {
     return(operations.BeginApplyNetworkConfigurationUpdatesAsync(resourceGroupName, serviceName, parameters).GetAwaiter().GetResult());
 }
Exemple #17
0
 /// <summary>
 /// Updates the Microsoft.ApiManagement resource running in the Virtual network
 /// to pick the updated network settings.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the Apply Network Configuration operation. If the
 /// parameters are empty, all the regions in which the Api Management service
 /// is deployed will be updated sequentially without incurring downtime in the
 /// region.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <ApiManagementServiceResource> BeginApplyNetworkConfigurationUpdatesAsync(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, ApiManagementServiceApplyNetworkConfigurationParameters parameters = default(ApiManagementServiceApplyNetworkConfigurationParameters), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.BeginApplyNetworkConfigurationUpdatesWithHttpMessagesAsync(resourceGroupName, serviceName, parameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemple #18
0
 /// <summary>
 /// Gets the Single-Sign-On token for the API Management Service which is valid
 /// for 5 Minutes.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 public static ApiManagementServiceGetSsoTokenResult GetSsoToken(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName)
 {
     return(operations.GetSsoTokenAsync(resourceGroupName, serviceName).GetAwaiter().GetResult());
 }
Exemple #19
0
 /// <summary>
 /// Creates a backup of the API Management service to the given Azure Storage
 /// Account. This is long running operation and could take several minutes to
 /// complete.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group.
 /// </param>
 /// <param name='serviceName'>
 /// The name of the API Management service.
 /// </param>
 /// <param name='parameters'>
 /// Parameters supplied to the ApiManagementService_Backup operation.
 /// </param>
 public static ApiManagementServiceResource Backup(this IApiManagementServiceOperations operations, string resourceGroupName, string serviceName, ApiManagementServiceBackupRestoreParameters parameters)
 {
     return(operations.BackupAsync(resourceGroupName, serviceName, parameters).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Get the custom domain ownership identifier for an API Management service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 public static ApiManagementServiceGetDomainOwnershipIdentifierResult GetDomainOwnershipIdentifier(this IApiManagementServiceOperations operations)
 {
     return(operations.GetDomainOwnershipIdentifierAsync().GetAwaiter().GetResult());
 }