/// <summary>
 /// Checks that the script name is valid and is not already in use.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group containing the Kusto cluster.
 /// </param>
 /// <param name='clusterName'>
 /// The name of the Kusto cluster.
 /// </param>
 /// <param name='databaseName'>
 /// The name of the database in the Kusto cluster.
 /// </param>
 /// <param name='scriptName'>
 /// The name of the script.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <CheckNameResult> CheckNameAvailabilityAsync(this IScriptsOperations operations, string resourceGroupName, string clusterName, string databaseName, ScriptCheckNameRequest scriptName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CheckNameAvailabilityWithHttpMessagesAsync(resourceGroupName, clusterName, databaseName, scriptName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Checks that the script name is valid and is not already in use.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group containing the Kusto cluster.
 /// </param>
 /// <param name='clusterName'>
 /// The name of the Kusto cluster.
 /// </param>
 /// <param name='databaseName'>
 /// The name of the database in the Kusto cluster.
 /// </param>
 /// <param name='scriptName'>
 /// The name of the script.
 /// </param>
 public static CheckNameResult CheckNameAvailability(this IScriptsOperations operations, string resourceGroupName, string clusterName, string databaseName, ScriptCheckNameRequest scriptName)
 {
     return(operations.CheckNameAvailabilityAsync(resourceGroupName, clusterName, databaseName, scriptName).GetAwaiter().GetResult());
 }