/// <summary> /// Lists customers which the current user can work with on-behalf of a /// partner. /// </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> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <IPage <Customer> > ListByBillingAccountNextAsync(this ICustomersOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListByBillingAccountNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Lists customers by billing profile which the current user can work with /// on-behalf of a partner. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='billingAccountName'> /// billing Account Id. /// </param> /// <param name='billingProfileName'> /// Billing Profile Id. /// </param> /// <param name='filter'> /// May be used to filter the list of customers. /// </param> /// <param name='skiptoken'> /// Skiptoken is only used if a previous operation returned a partial result. /// If a previous response contains a nextLink element, the value of the /// nextLink element will include a skiptoken parameter that specifies a /// starting point to use for subsequent calls. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <IPage <Customer> > ListByBillingProfileAsync(this ICustomersOperations operations, string billingAccountName, string billingProfileName, string filter = default(string), string skiptoken = default(string), CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.ListByBillingProfileWithHttpMessagesAsync(billingAccountName, billingProfileName, filter, skiptoken, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Gets a customer by its id. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='billingAccountName'> /// billing Account Id. /// </param> /// <param name='customerName'> /// Customer name. /// </param> /// <param name='expand'> /// May be used to expand enabledAzurePlans, resellers. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <Customer> GetAsync(this ICustomersOperations operations, string billingAccountName, string customerName, string expand = default(string), CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.GetWithHttpMessagesAsync(billingAccountName, customerName, expand, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Lists customers by billing profile which the current user can work with /// on-behalf of a partner. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='billingAccountName'> /// billing Account Id. /// </param> /// <param name='billingProfileName'> /// Billing Profile Id. /// </param> /// <param name='filter'> /// May be used to filter the list of customers. /// </param> /// <param name='skiptoken'> /// Skiptoken is only used if a previous operation returned a partial result. /// If a previous response contains a nextLink element, the value of the /// nextLink element will include a skiptoken parameter that specifies a /// starting point to use for subsequent calls. /// </param> public static IPage <Customer> ListByBillingProfile(this ICustomersOperations operations, string billingAccountName, string billingProfileName, string filter = default(string), string skiptoken = default(string)) { return(operations.ListByBillingProfileAsync(billingAccountName, billingProfileName, filter, skiptoken).GetAwaiter().GetResult()); }
/// <summary> /// Lists customers which the current user can work with on-behalf of a /// partner. /// </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 <Customer> ListByBillingAccountNext(this ICustomersOperations operations, string nextPageLink) { return(operations.ListByBillingAccountNextAsync(nextPageLink).GetAwaiter().GetResult()); }
/// <summary> /// Gets a customer by its id. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='billingAccountName'> /// billing Account Id. /// </param> /// <param name='customerName'> /// Customer name. /// </param> /// <param name='expand'> /// May be used to expand enabledAzurePlans, resellers. /// </param> public static Customer Get(this ICustomersOperations operations, string billingAccountName, string customerName, string expand = default(string)) { return(operations.GetAsync(billingAccountName, customerName, expand).GetAwaiter().GetResult()); }
/// <summary> /// Lists the customers that are billed to a billing account. The operation is /// supported only for billing accounts with agreement type Microsoft Partner /// Agreement. /// <see href="https://docs.microsoft.com/en-us/rest/api/billing/" /> /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='billingAccountName'> /// The ID that uniquely identifies a billing account. /// </param> /// <param name='search'> /// Used for searching customers by their name. Any customer with name /// containing the search text will be included in the response /// </param> /// <param name='filter'> /// May be used to filter the list of customers. /// </param> public static IPage <Customer> ListByBillingAccount(this ICustomersOperations operations, string billingAccountName, string search = default(string), string filter = default(string)) { return(operations.ListByBillingAccountAsync(billingAccountName, search, filter).GetAwaiter().GetResult()); }