Skip to content

Commit

Permalink
[AutoPR Microsoft.Azure.Management.Subscription] [Hub Generated] Revi…
Browse files Browse the repository at this point in the history
…ew request for Microsoft.Subscription to add version preview/2018-11-01-preview (#250)

* Update swagger_to_sdk_config.json

* Generated from 12cf92bb36d2c853720ea3480580c9ef415f9984

Corrected the createSubscriptionUnderBillingProfile example with correct profile name.
  • Loading branch information
openapi-sdkautomation[bot] authored and SDK Automation committed Oct 25, 2019
1 parent e6099e7 commit 886ac4a
Show file tree
Hide file tree
Showing 13 changed files with 1,500 additions and 430 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -70,14 +70,14 @@ public partial interface ISubscriptionClient : System.IDisposable
ISubscriptionOperationOperations SubscriptionOperation { get; }

/// <summary>
/// Gets the ISubscriptionFactoryOperations.
/// Gets the ISubscriptionOperations.
/// </summary>
ISubscriptionFactoryOperations SubscriptionFactory { get; }
ISubscriptionOperations SubscriptionOperations { get; }

/// <summary>
/// Gets the ISubscriptionOperations.
/// Gets the ISubscriptionFactoryOperations.
/// </summary>
ISubscriptionOperations SubscriptionOperations { get; }
ISubscriptionFactoryOperations SubscriptionFactory { get; }

/// <summary>
/// Gets the IOperations.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,36 +23,6 @@ namespace Microsoft.Azure.Management.Subscription
/// </summary>
public partial interface ISubscriptionFactoryOperations
{
/// <summary>
/// The operation to create a new Azure subscription
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='invoiceSectionName'>
/// The name of the invoice section in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionFactoryCreateSubscriptionHeaders>> CreateSubscriptionWithHttpMessagesAsync(string billingAccountName, string invoiceSectionName, ModernSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Creates an Azure subscription
/// </summary>
Expand Down Expand Up @@ -80,36 +50,6 @@ public partial interface ISubscriptionFactoryOperations
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionFactoryCreateSubscriptionInEnrollmentAccountHeaders>> CreateSubscriptionInEnrollmentAccountWithHttpMessagesAsync(string enrollmentAccountName, SubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// The operation to create a new Azure subscription
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='invoiceSectionName'>
/// The name of the invoice section in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionFactoryCreateSubscriptionHeaders>> BeginCreateSubscriptionWithHttpMessagesAsync(string billingAccountName, string invoiceSectionName, ModernSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Creates an Azure subscription
/// </summary>
/// <param name='enrollmentAccountName'>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,100 @@ public partial interface ISubscriptionsOperations
/// </exception>
Task<AzureOperationResponse<EnabledSubscriptionId>> EnableWithHttpMessagesAsync(string subscriptionId, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// The operation to create a new WebDirect or EA Azure subscription.
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='invoiceSectionName'>
/// The name of the invoice section in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionsCreateSubscriptionHeaders>> CreateSubscriptionWithHttpMessagesAsync(string billingAccountName, string invoiceSectionName, ModernSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// The operation to create a new WebDirect or EA Azure subscription
/// (under billingProfiles).
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='billingProfileName'>
/// The name of the billing profile in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='invoiceSectionName'>
/// The name of the invoice section in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionsCreateSubscriptionUnderBillingProfileHeaders>> CreateSubscriptionUnderBillingProfileWithHttpMessagesAsync(string billingAccountName, string billingProfileName, string invoiceSectionName, ModernSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// The operation to create a new CSP subscription.
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='customerName'>
/// The name of the customer.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionsCreateCspSubscriptionHeaders>> CreateCspSubscriptionWithHttpMessagesAsync(string billingAccountName, string customerName, ModernCspSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Gets all available geo-locations.
/// </summary>
/// <remarks>
Expand Down Expand Up @@ -161,6 +255,100 @@ public partial interface ISubscriptionsOperations
/// </exception>
Task<AzureOperationResponse<IPage<SubscriptionModel>>> ListWithHttpMessagesAsync(Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// The operation to create a new WebDirect or EA Azure subscription.
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='invoiceSectionName'>
/// The name of the invoice section in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionsCreateSubscriptionHeaders>> BeginCreateSubscriptionWithHttpMessagesAsync(string billingAccountName, string invoiceSectionName, ModernSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// The operation to create a new WebDirect or EA Azure subscription
/// (under billingProfiles).
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='billingProfileName'>
/// The name of the billing profile in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='invoiceSectionName'>
/// The name of the invoice section in the billing account for which
/// you want to create the subscription.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionsCreateSubscriptionUnderBillingProfileHeaders>> BeginCreateSubscriptionUnderBillingProfileWithHttpMessagesAsync(string billingAccountName, string billingProfileName, string invoiceSectionName, ModernSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// The operation to create a new CSP subscription.
/// </summary>
/// <param name='billingAccountName'>
/// The name of the Microsoft Customer Agreement billing account for
/// which you want to create the subscription.
/// </param>
/// <param name='customerName'>
/// The name of the customer.
/// </param>
/// <param name='body'>
/// The subscription creation parameters.
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
/// </param>
/// <exception cref="ErrorResponseException">
/// Thrown when the operation returned an invalid status code
/// </exception>
/// <exception cref="Microsoft.Rest.SerializationException">
/// Thrown when unable to deserialize the response
/// </exception>
/// <exception cref="Microsoft.Rest.ValidationException">
/// Thrown when a required parameter is null
/// </exception>
Task<AzureOperationResponse<SubscriptionCreationResult,SubscriptionsCreateCspSubscriptionHeaders>> BeginCreateCspSubscriptionWithHttpMessagesAsync(string billingAccountName, string customerName, ModernCspSubscriptionCreationParameters body, Dictionary<string, List<string>> customHeaders = null, CancellationToken cancellationToken = default(CancellationToken));
/// <summary>
/// Gets all subscriptions for a tenant.
/// </summary>
/// <param name='nextPageLink'>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
// <auto-generated>
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for
// license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
// Changes may cause incorrect behavior and will be lost if the code is
// regenerated.
// </auto-generated>

namespace Microsoft.Azure.Management.Subscription.Models
{
using Microsoft.Rest;
using Newtonsoft.Json;
using System.Linq;

/// <summary>
/// The parameters required to create a new CSP subscription.
/// </summary>
public partial class ModernCspSubscriptionCreationParameters
{
/// <summary>
/// Initializes a new instance of the
/// ModernCspSubscriptionCreationParameters class.
/// </summary>
public ModernCspSubscriptionCreationParameters()
{
CustomInit();
}

/// <summary>
/// Initializes a new instance of the
/// ModernCspSubscriptionCreationParameters class.
/// </summary>
/// <param name="displayName">The friendly name of the
/// subscription.</param>
/// <param name="skuId">The SKU ID of the Azure plan. Azure plan
/// determines the pricing and service-level agreement of the
/// subscription. Use 001 for Microsoft Azure Plan and 002 for
/// Microsoft Azure Plan for DevTest.</param>
/// <param name="resellerId">Reseller ID, basically MPN Id.</param>
/// <param name="serviceProviderId">Service provider ID, basically MPN
/// Id.</param>
public ModernCspSubscriptionCreationParameters(string displayName, string skuId, string resellerId = default(string), string serviceProviderId = default(string))
{
DisplayName = displayName;
SkuId = skuId;
ResellerId = resellerId;
ServiceProviderId = serviceProviderId;
CustomInit();
}

/// <summary>
/// An initialization method that performs custom operations like setting defaults
/// </summary>
partial void CustomInit();

/// <summary>
/// Gets or sets the friendly name of the subscription.
/// </summary>
[JsonProperty(PropertyName = "displayName")]
public string DisplayName { get; set; }

/// <summary>
/// Gets or sets the SKU ID of the Azure plan. Azure plan determines
/// the pricing and service-level agreement of the subscription. Use
/// 001 for Microsoft Azure Plan and 002 for Microsoft Azure Plan for
/// DevTest.
/// </summary>
[JsonProperty(PropertyName = "skuId")]
public string SkuId { get; set; }

/// <summary>
/// Gets or sets reseller ID, basically MPN Id.
/// </summary>
[JsonProperty(PropertyName = "resellerId")]
public string ResellerId { get; set; }

/// <summary>
/// Gets or sets service provider ID, basically MPN Id.
/// </summary>
[JsonProperty(PropertyName = "serviceProviderId")]
public string ServiceProviderId { get; set; }

/// <summary>
/// Validate the object.
/// </summary>
/// <exception cref="ValidationException">
/// Thrown if validation fails
/// </exception>
public virtual void Validate()
{
if (DisplayName == null)
{
throw new ValidationException(ValidationRules.CannotBeNull, "DisplayName");
}
if (SkuId == null)
{
throw new ValidationException(ValidationRules.CannotBeNull, "SkuId");
}
}
}
}
Loading

0 comments on commit 886ac4a

Please sign in to comment.