diff --git a/packages/@azure/arm-apimanagement/LICENSE.txt b/packages/@azure/arm-apimanagement/LICENSE.txt index 5431ba98b936..8f3d856145c5 100644 --- a/packages/@azure/arm-apimanagement/LICENSE.txt +++ b/packages/@azure/arm-apimanagement/LICENSE.txt @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2018 Microsoft +Copyright (c) 2019 Microsoft Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/packages/@azure/arm-apimanagement/README.md b/packages/@azure/arm-apimanagement/README.md index bb77bf0bdd00..e4b83f2591c8 100644 --- a/packages/@azure/arm-apimanagement/README.md +++ b/packages/@azure/arm-apimanagement/README.md @@ -9,7 +9,7 @@ This package contains an isomorphic SDK for ApiManagementClient. ### How to Install -``` +```bash npm install @azure/arm-apimanagement ``` @@ -19,13 +19,13 @@ npm install @azure/arm-apimanagement ##### Install @azure/ms-rest-nodeauth -``` +```bash npm install @azure/ms-rest-nodeauth ``` ##### Sample code -```ts +```typescript import * as msRest from "@azure/ms-rest-js"; import * as msRestAzure from "@azure/ms-rest-azure-js"; import * as msRestNodeAuth from "@azure/ms-rest-nodeauth"; @@ -50,7 +50,7 @@ msRestNodeAuth.interactiveLogin().then((creds) => { ##### Install @azure/ms-rest-browserauth -``` +```bash npm install @azure/ms-rest-browserauth ``` diff --git a/packages/@azure/arm-apimanagement/lib/apiManagementClient.ts b/packages/@azure/arm-apimanagement/lib/apiManagementClient.ts index ee9357bd6dfb..662320ae6241 100644 --- a/packages/@azure/arm-apimanagement/lib/apiManagementClient.ts +++ b/packages/@azure/arm-apimanagement/lib/apiManagementClient.ts @@ -37,6 +37,7 @@ class ApiManagementClient extends ApiManagementClientContext { backend: operations.Backend; certificate: operations.Certificate; apiManagementOperations: operations.ApiManagementOperations; + apiManagementServiceSkus: operations.ApiManagementServiceSkus; apiManagementService: operations.ApiManagementService; diagnostic: operations.Diagnostic; diagnosticLogger: operations.DiagnosticLogger; @@ -106,6 +107,7 @@ class ApiManagementClient extends ApiManagementClientContext { this.backend = new operations.Backend(this); this.certificate = new operations.Certificate(this); this.apiManagementOperations = new operations.ApiManagementOperations(this); + this.apiManagementServiceSkus = new operations.ApiManagementServiceSkus(this); this.apiManagementService = new operations.ApiManagementService(this); this.diagnostic = new operations.Diagnostic(this); this.diagnosticLogger = new operations.DiagnosticLogger(this); diff --git a/packages/@azure/arm-apimanagement/lib/apiManagementClientContext.ts b/packages/@azure/arm-apimanagement/lib/apiManagementClientContext.ts index 316679a0aa97..c6b3f59b4743 100644 --- a/packages/@azure/arm-apimanagement/lib/apiManagementClientContext.ts +++ b/packages/@azure/arm-apimanagement/lib/apiManagementClientContext.ts @@ -13,7 +13,7 @@ import * as msRest from "@azure/ms-rest-js"; import * as msRestAzure from "@azure/ms-rest-azure-js"; const packageName = "@azure/arm-apimanagement"; -const packageVersion = "0.1.0"; +const packageVersion = "4.4.0"; export class ApiManagementClientContext extends msRestAzure.AzureServiceClient { credentials: msRest.ServiceClientCredentials; diff --git a/packages/@azure/arm-apimanagement/lib/models/apiManagementServiceSkusMappers.ts b/packages/@azure/arm-apimanagement/lib/models/apiManagementServiceSkusMappers.ts new file mode 100644 index 000000000000..41b68c6abb39 --- /dev/null +++ b/packages/@azure/arm-apimanagement/lib/models/apiManagementServiceSkusMappers.ts @@ -0,0 +1,18 @@ +/* + * 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. + */ + +export { + ResourceSkuResults, + ResourceSkuResult, + ResourceSku, + ResourceSkuCapacity, + CloudError +} from "../models/mappers"; + diff --git a/packages/@azure/arm-apimanagement/lib/models/index.ts b/packages/@azure/arm-apimanagement/lib/models/index.ts index 46ee80cc83c6..15c943566d21 100644 --- a/packages/@azure/arm-apimanagement/lib/models/index.ts +++ b/packages/@azure/arm-apimanagement/lib/models/index.ts @@ -1955,7 +1955,7 @@ export interface BackendServiceFabricClusterProperties { clientCertificatethumbprint: string; /** * @member {number} [maxPartitionResolutionRetries] Maximum number of retries - * while attempting resolve the parition. + * while attempting resolve the partition. */ maxPartitionResolutionRetries?: number; /** @@ -2209,7 +2209,7 @@ export interface BackendUpdateParameters { export interface BackendReconnectContract extends Resource { /** * @member {string} [after] Duration in ISO8601 format after which reconnect - * will be initiated. Minimum duration of the Reconect is PT2M. + * will be initiated. Minimum duration of the Reconnect is PT2M. */ after?: string; } @@ -2256,6 +2256,83 @@ export interface CertificateCreateOrUpdateParameters { password: string; } +/** + * @interface + * An interface representing ResourceSku. + * Describes an available API Management SKU. + * + */ +export interface ResourceSku { + /** + * @member {SkuType} [name] Name of the Sku. Possible values include: + * 'Developer', 'Standard', 'Premium', 'Basic' + */ + name?: SkuType; +} + +/** + * @interface + * An interface representing ResourceSkuCapacity. + * Describes scaling information of a SKU. + * + */ +export interface ResourceSkuCapacity { + /** + * @member {number} [minimum] The minimum capacity. + * **NOTE: This property will not be serialized. It can only be populated by + * the server.** + */ + readonly minimum?: number; + /** + * @member {number} [maximum] The maximum capacity that can be set. + * **NOTE: This property will not be serialized. It can only be populated by + * the server.** + */ + readonly maximum?: number; + /** + * @member {number} [default] The default capacity. + * **NOTE: This property will not be serialized. It can only be populated by + * the server.** + */ + readonly default?: number; + /** + * @member {ResourceSkuCapacityScaleType} [scaleType] The scale type + * applicable to the sku. Possible values include: 'automatic', 'manual', + * 'none' + * **NOTE: This property will not be serialized. It can only be populated by + * the server.** + */ + readonly scaleType?: ResourceSkuCapacityScaleType; +} + +/** + * @interface + * An interface representing ResourceSkuResult. + * Describes an available API Management service SKU. + * + */ +export interface ResourceSkuResult { + /** + * @member {string} [resourceType] The type of resource the SKU applies to. + * **NOTE: This property will not be serialized. It can only be populated by + * the server.** + */ + readonly resourceType?: string; + /** + * @member {ResourceSku} [sku] Specifies API Management SKU. + * **NOTE: This property will not be serialized. It can only be populated by + * the server.** + */ + readonly sku?: ResourceSku; + /** + * @member {ResourceSkuCapacity} [capacity] Specifies the number of API + * Management units. + * **NOTE: This property will not be serialized. It can only be populated by + * the server.** + */ + readonly capacity?: ResourceSkuCapacity; +} + /** * @interface * An interface representing CertificateInformation. @@ -2297,7 +2374,7 @@ export interface CertificateConfiguration { certificatePassword?: string; /** * @member {StoreName} storeName The - * System.Security.Cryptography.x509certificates.Storename certificate store + * System.Security.Cryptography.x509certificates.StoreName certificate store * location. Only Root and CertificateAuthority are valid locations. Possible * values include: 'CertificateAuthority', 'Root' */ @@ -2608,7 +2685,7 @@ export interface ApiManagementServiceBaseProperties { certificates?: CertificateConfiguration[]; /** * @member {VirtualNetworkType} [virtualNetworkType] The type of VPN in which - * API Managemet service needs to be configured in. None (Default Value) + * API Management service needs to be configured in. None (Default Value) * means the API Management service is not part of any Virtual Network, * External means the API Management deployment is set up inside a Virtual * Network having an Internet Facing Endpoint, and Internal means that API @@ -2795,7 +2872,7 @@ export interface ApiManagementServiceResource extends ApimResource { certificates?: CertificateConfiguration[]; /** * @member {VirtualNetworkType} [virtualNetworkType] The type of VPN in which - * API Managemet service needs to be configured in. None (Default Value) + * API Management service needs to be configured in. None (Default Value) * means the API Management service is not part of any Virtual Network, * External means the API Management deployment is set up inside a Virtual * Network having an Internet Facing Endpoint, and Internal means that API @@ -2956,7 +3033,7 @@ export interface ApiManagementServiceUpdateParameters extends ApimResource { certificates?: CertificateConfiguration[]; /** * @member {VirtualNetworkType} [virtualNetworkType] The type of VPN in which - * API Managemet service needs to be configured in. None (Default Value) + * API Management service needs to be configured in. None (Default Value) * means the API Management service is not part of any Virtual Network, * External means the API Management deployment is set up inside a Virtual * Network having an Internet Facing Endpoint, and Internal means that API @@ -4378,8 +4455,8 @@ export interface ReportRecordContract { */ timestamp?: Date; /** - * @member {string} [interval] Length of agregation period. Interval must be - * multiple of 15 minutes and may not be zero. The value should be in ISO + * @member {string} [interval] Length of aggregation period. Interval must + * be multiple of 15 minutes and may not be zero. The value should be in ISO * 8601 format (http://en.wikipedia.org/wiki/ISO_8601#Durations). */ interval?: string; @@ -4428,14 +4505,14 @@ export interface ReportRecordContract { */ subscriptionId?: string; /** - * @member {number} [callCountSuccess] Number of succesful calls. This + * @member {number} [callCountSuccess] Number of successful calls. This * includes calls returning HttpStatusCode <= 301 and * HttpStatusCode.NotModified and HttpStatusCode.TemporaryRedirect */ callCountSuccess?: number; /** * @member {number} [callCountBlocked] Number of calls blocked due to invalid - * credentials. This includes calls returning HttpStatusCode.Unauthorize and + * credentials. This includes calls returning HttpStatusCode.Unauthorized and * HttpStatusCode.Forbidden and HttpStatusCode.TooManyRequests */ callCountBlocked?: number; @@ -4563,7 +4640,7 @@ export interface RequestReportRecordContract { * @member {string} [cache] Specifies if response cache was involved in * generating the response. If the value is none, the cache was not used. If * the value is hit, cached response was returned. If the value is miss, the - * cache was used but lookup resulted in a miss and request was fullfilled by + * cache was used but lookup resulted in a miss and request was fulfilled by * the backend. */ cache?: string; @@ -4610,7 +4687,7 @@ export interface SubscriptionCreateParameters { userId: string; /** * @member {string} productId Product (product id path) for which - * subscription is being created in form /products/{productid} + * subscription is being created in form /products/{productId} */ productId: string; /** @@ -8498,6 +8575,21 @@ export interface OperationListResult extends Array { nextLink?: string; } +/** + * @interface + * An interface representing the ResourceSkuResults. + * The API Management service SKUs operation response. + * + * @extends Array + */ +export interface ResourceSkuResults extends Array { + /** + * @member {string} [nextLink] The uri to fetch the next page of API + * Management service Skus. + */ + nextLink?: string; +} + /** * @interface * An interface representing the ApiManagementServiceListResult. @@ -8832,20 +8924,28 @@ export type BearerTokenSendingMethod = 'authorizationHeader' | 'query'; export type BackendProtocol = 'http' | 'soap'; /** - * Defines values for HostnameType. - * Possible values include: 'Proxy', 'Portal', 'Management', 'Scm' + * Defines values for SkuType. + * Possible values include: 'Developer', 'Standard', 'Premium', 'Basic' * @readonly * @enum {string} */ -export type HostnameType = 'Proxy' | 'Portal' | 'Management' | 'Scm'; +export type SkuType = 'Developer' | 'Standard' | 'Premium' | 'Basic'; /** - * Defines values for SkuType. - * Possible values include: 'Developer', 'Standard', 'Premium', 'Basic' + * Defines values for ResourceSkuCapacityScaleType. + * Possible values include: 'automatic', 'manual', 'none' * @readonly * @enum {string} */ -export type SkuType = 'Developer' | 'Standard' | 'Premium' | 'Basic'; +export type ResourceSkuCapacityScaleType = 'automatic' | 'manual' | 'none'; + +/** + * Defines values for HostnameType. + * Possible values include: 'Proxy', 'Portal', 'Management', 'Scm' + * @readonly + * @enum {string} + */ +export type HostnameType = 'Proxy' | 'Portal' | 'Management' | 'Scm'; /** * Defines values for VirtualNetworkType. @@ -10543,6 +10643,44 @@ export type ApiManagementOperationsListNextResponse = OperationListResult & { }; }; +/** + * Contains response data for the listAvailableServiceSkus operation. + */ +export type ApiManagementServiceSkusListAvailableServiceSkusResponse = ResourceSkuResults & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + /** + * The response body as parsed JSON or XML + */ + parsedBody: ResourceSkuResults; + }; +}; + +/** + * Contains response data for the listAvailableServiceSkusNext operation. + */ +export type ApiManagementServiceSkusListAvailableServiceSkusNextResponse = ResourceSkuResults & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + /** + * The response body as parsed JSON or XML + */ + parsedBody: ResourceSkuResults; + }; +}; + /** * Contains response data for the restore operation. */ diff --git a/packages/@azure/arm-apimanagement/lib/models/mappers.ts b/packages/@azure/arm-apimanagement/lib/models/mappers.ts index b18a83ba8e85..a1c362ca6420 100644 --- a/packages/@azure/arm-apimanagement/lib/models/mappers.ts +++ b/packages/@azure/arm-apimanagement/lib/models/mappers.ts @@ -3254,6 +3254,98 @@ export const CertificateCreateOrUpdateParameters: msRest.CompositeMapper = { } }; +export const ResourceSku: msRest.CompositeMapper = { + serializedName: "ResourceSku", + type: { + name: "Composite", + className: "ResourceSku", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + } + } + } +}; + +export const ResourceSkuCapacity: msRest.CompositeMapper = { + serializedName: "ResourceSkuCapacity", + type: { + name: "Composite", + className: "ResourceSkuCapacity", + modelProperties: { + minimum: { + readOnly: true, + serializedName: "minimum", + type: { + name: "Number" + } + }, + maximum: { + readOnly: true, + serializedName: "maximum", + type: { + name: "Number" + } + }, + default: { + readOnly: true, + serializedName: "default", + type: { + name: "Number" + } + }, + scaleType: { + readOnly: true, + serializedName: "scaleType", + type: { + name: "Enum", + allowedValues: [ + "automatic", + "manual", + "none" + ] + } + } + } + } +}; + +export const ResourceSkuResult: msRest.CompositeMapper = { + serializedName: "ResourceSkuResult", + type: { + name: "Composite", + className: "ResourceSkuResult", + modelProperties: { + resourceType: { + readOnly: true, + serializedName: "resourceType", + type: { + name: "String" + } + }, + sku: { + readOnly: true, + serializedName: "sku", + type: { + name: "Composite", + className: "ResourceSku" + } + }, + capacity: { + readOnly: true, + serializedName: "capacity", + type: { + name: "Composite", + className: "ResourceSkuCapacity" + } + } + } + } +}; + export const CertificateInformation: msRest.CompositeMapper = { serializedName: "CertificateInformation", type: { @@ -8994,6 +9086,35 @@ export const OperationListResult: msRest.CompositeMapper = { } }; +export const ResourceSkuResults: msRest.CompositeMapper = { + serializedName: "ResourceSkuResults", + type: { + name: "Composite", + className: "ResourceSkuResults", + modelProperties: { + value: { + required: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceSkuResult" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + export const ApiManagementServiceListResult: msRest.CompositeMapper = { serializedName: "ApiManagementServiceListResult", type: { diff --git a/packages/@azure/arm-apimanagement/lib/operations/apiDiagnosticLogger.ts b/packages/@azure/arm-apimanagement/lib/operations/apiDiagnosticLogger.ts index b69c5bf8fd2a..3cdcfe360ad0 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/apiDiagnosticLogger.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/apiDiagnosticLogger.ts @@ -27,7 +27,7 @@ export class ApiDiagnosticLogger { } /** - * Lists all loggers assosiated with the specified Diagnostic of an API. + * Lists all loggers associated with the specified Diagnostic of an API. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param apiId API identifier. Must be unique in the current API Management service instance. @@ -117,7 +117,7 @@ export class ApiDiagnosticLogger { } /** - * Attaches a logger to a dignostic for an API. + * Attaches a logger to a diagnostic for an API. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param apiId API identifier. Must be unique in the current API Management service instance. @@ -211,7 +211,7 @@ export class ApiDiagnosticLogger { } /** - * Lists all loggers assosiated with the specified Diagnostic of an API. + * Lists all loggers associated with the specified Diagnostic of an API. * @param nextPageLink The NextLink from the previous successful call to List operation. * @param [options] The optional parameters * @returns Promise diff --git a/packages/@azure/arm-apimanagement/lib/operations/apiIssue.ts b/packages/@azure/arm-apimanagement/lib/operations/apiIssue.ts index 4b268000cb83..c4edfe80555c 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/apiIssue.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/apiIssue.ts @@ -27,7 +27,7 @@ export class ApiIssue { } /** - * Lists all issues assosiated with the specified API. + * Lists all issues associated with the specified API. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param apiId API identifier. Must be unique in the current API Management service instance. @@ -278,7 +278,7 @@ export class ApiIssue { } /** - * Lists all issues assosiated with the specified API. + * Lists all issues associated with the specified API. * @param nextPageLink The NextLink from the previous successful call to List operation. * @param [options] The optional parameters * @returns Promise diff --git a/packages/@azure/arm-apimanagement/lib/operations/apiIssueAttachment.ts b/packages/@azure/arm-apimanagement/lib/operations/apiIssueAttachment.ts index ff352c52fc93..89b59eaaa2c4 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/apiIssueAttachment.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/apiIssueAttachment.ts @@ -27,7 +27,7 @@ export class ApiIssueAttachment { } /** - * Lists all comments for the Issue assosiated with the specified API. + * Lists all comments for the Issue associated with the specified API. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param apiId API identifier. Must be unique in the current API Management service instance. @@ -255,7 +255,7 @@ export class ApiIssueAttachment { } /** - * Lists all comments for the Issue assosiated with the specified API. + * Lists all comments for the Issue associated with the specified API. * @param nextPageLink The NextLink from the previous successful call to List operation. * @param [options] The optional parameters * @returns Promise diff --git a/packages/@azure/arm-apimanagement/lib/operations/apiIssueComment.ts b/packages/@azure/arm-apimanagement/lib/operations/apiIssueComment.ts index c249a1108922..49b67f0db373 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/apiIssueComment.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/apiIssueComment.ts @@ -27,7 +27,7 @@ export class ApiIssueComment { } /** - * Lists all comments for the Issue assosiated with the specified API. + * Lists all comments for the Issue associated with the specified API. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param apiId API identifier. Must be unique in the current API Management service instance. @@ -255,7 +255,7 @@ export class ApiIssueComment { } /** - * Lists all comments for the Issue assosiated with the specified API. + * Lists all comments for the Issue associated with the specified API. * @param nextPageLink The NextLink from the previous successful call to List operation. * @param [options] The optional parameters * @returns Promise diff --git a/packages/@azure/arm-apimanagement/lib/operations/apiManagementServiceSkus.ts b/packages/@azure/arm-apimanagement/lib/operations/apiManagementServiceSkus.ts new file mode 100644 index 000000000000..4ed93c82e480 --- /dev/null +++ b/packages/@azure/arm-apimanagement/lib/operations/apiManagementServiceSkus.ts @@ -0,0 +1,138 @@ +/* + * 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. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/apiManagementServiceSkusMappers"; +import * as Parameters from "../models/parameters"; +import { ApiManagementClientContext } from "../apiManagementClientContext"; + +/** Class representing a ApiManagementServiceSkus. */ +export class ApiManagementServiceSkus { + private readonly client: ApiManagementClientContext; + + /** + * Create a ApiManagementServiceSkus. + * @param {ApiManagementClientContext} client Reference to the service client. + */ + constructor(client: ApiManagementClientContext) { + this.client = client; + } + + /** + * Gets all available SKU for a given API Management service + * @summary Gets available SKUs for API Management service + * @param resourceGroupName The name of the resource group. + * @param serviceName The name of the API Management service. + * @param [options] The optional parameters + * @returns Promise + */ + listAvailableServiceSkus(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName The name of the resource group. + * @param serviceName The name of the API Management service. + * @param callback The callback + */ + listAvailableServiceSkus(resourceGroupName: string, serviceName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The name of the resource group. + * @param serviceName The name of the API Management service. + * @param options The optional parameters + * @param callback The callback + */ + listAvailableServiceSkus(resourceGroupName: string, serviceName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listAvailableServiceSkus(resourceGroupName: string, serviceName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + serviceName, + options + }, + listAvailableServiceSkusOperationSpec, + callback) as Promise; + } + + /** + * Gets all available SKU for a given API Management service + * @summary Gets available SKUs for API Management service + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listAvailableServiceSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listAvailableServiceSkusNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listAvailableServiceSkusNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listAvailableServiceSkusNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listAvailableServiceSkusNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listAvailableServiceSkusOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ApiManagement/service/{serviceName}/skus", + urlParameters: [ + Parameters.resourceGroupName, + Parameters.serviceName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ResourceSkuResults + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listAvailableServiceSkusNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ResourceSkuResults + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/packages/@azure/arm-apimanagement/lib/operations/diagnosticLogger.ts b/packages/@azure/arm-apimanagement/lib/operations/diagnosticLogger.ts index 02f21823974c..5bbc80ffe27e 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/diagnosticLogger.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/diagnosticLogger.ts @@ -27,7 +27,7 @@ export class DiagnosticLogger { } /** - * Lists all loggers assosiated with the specified Diagnostic of the API Management service + * Lists all loggers associated with the specified Diagnostic of the API Management service * instance. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. @@ -110,7 +110,7 @@ export class DiagnosticLogger { } /** - * Attaches a logger to a dignostic. + * Attaches a logger to a diagnostic. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param diagnosticId Diagnostic identifier. Must be unique in the current API Management service @@ -196,7 +196,7 @@ export class DiagnosticLogger { } /** - * Lists all loggers assosiated with the specified Diagnostic of the API Management service + * Lists all loggers associated with the specified Diagnostic of the API Management service * instance. * @param nextPageLink The NextLink from the previous successful call to List operation. * @param [options] The optional parameters diff --git a/packages/@azure/arm-apimanagement/lib/operations/index.ts b/packages/@azure/arm-apimanagement/lib/operations/index.ts index a50144467427..2905e38f2ea9 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/index.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/index.ts @@ -28,6 +28,7 @@ export * from "./authorizationServer"; export * from "./backend"; export * from "./certificate"; export * from "./apiManagementOperations"; +export * from "./apiManagementServiceSkus"; export * from "./apiManagementService"; export * from "./diagnostic"; export * from "./diagnosticLogger"; diff --git a/packages/@azure/arm-apimanagement/lib/operations/property.ts b/packages/@azure/arm-apimanagement/lib/operations/property.ts index 5358544f679e..cd2c09f67192 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/property.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/property.ts @@ -218,7 +218,7 @@ export class Property { } /** - * Deletes specific property from the the API Management service instance. + * Deletes specific property from the API Management service instance. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param propId Identifier of the property. diff --git a/packages/@azure/arm-apimanagement/lib/operations/reports.ts b/packages/@azure/arm-apimanagement/lib/operations/reports.ts index e02b15b6da63..c0bd458bb187 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/reports.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/reports.ts @@ -171,7 +171,7 @@ export class Reports { } /** - * Lists report records by GeoGraphy. + * Lists report records by geography. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param [options] The optional parameters @@ -241,7 +241,7 @@ export class Reports { * @param interval By time interval. Interval must be multiple of 15 minutes and may not be zero. * The value should be in ISO 8601 format (http://en.wikipedia.org/wiki/ISO_8601#Durations).This * code can be used to convert TimeSpan to a valid interval string: XmlConvert.ToString(new - * TimeSpan(hours, minutes, secconds)) + * TimeSpan(hours, minutes, seconds)) * @param [options] The optional parameters * @returns Promise */ @@ -252,7 +252,7 @@ export class Reports { * @param interval By time interval. Interval must be multiple of 15 minutes and may not be zero. * The value should be in ISO 8601 format (http://en.wikipedia.org/wiki/ISO_8601#Durations).This * code can be used to convert TimeSpan to a valid interval string: XmlConvert.ToString(new - * TimeSpan(hours, minutes, secconds)) + * TimeSpan(hours, minutes, seconds)) * @param callback The callback */ listByTime(resourceGroupName: string, serviceName: string, interval: string, callback: msRest.ServiceCallback): void; @@ -262,7 +262,7 @@ export class Reports { * @param interval By time interval. Interval must be multiple of 15 minutes and may not be zero. * The value should be in ISO 8601 format (http://en.wikipedia.org/wiki/ISO_8601#Durations).This * code can be used to convert TimeSpan to a valid interval string: XmlConvert.ToString(new - * TimeSpan(hours, minutes, secconds)) + * TimeSpan(hours, minutes, seconds)) * @param options The optional parameters * @param callback The callback */ @@ -428,7 +428,7 @@ export class Reports { } /** - * Lists report records by GeoGraphy. + * Lists report records by geography. * @param nextPageLink The NextLink from the previous successful call to List operation. * @param [options] The optional parameters * @returns Promise diff --git a/packages/@azure/arm-apimanagement/lib/operations/subscription.ts b/packages/@azure/arm-apimanagement/lib/operations/subscription.ts index 3341301d7a95..8e1a4b14fffa 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/subscription.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/subscription.ts @@ -181,7 +181,7 @@ export class Subscription { } /** - * Updates the details of a subscription specificied by its identifier. + * Updates the details of a subscription specified by its identifier. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param sid Subscription entity Identifier. The entity represents the association between a user diff --git a/packages/@azure/arm-apimanagement/lib/operations/tagDescription.ts b/packages/@azure/arm-apimanagement/lib/operations/tagDescription.ts index d7d02d435e6d..c1a0159e1b95 100644 --- a/packages/@azure/arm-apimanagement/lib/operations/tagDescription.ts +++ b/packages/@azure/arm-apimanagement/lib/operations/tagDescription.ts @@ -153,7 +153,7 @@ export class TagDescription { } /** - * Create/Update tag fescription in scope of the Api. + * Create/Update tag description in scope of the Api. * @param resourceGroupName The name of the resource group. * @param serviceName The name of the API Management service. * @param apiId API revision identifier. Must be unique in the current API Management service diff --git a/packages/@azure/arm-apimanagement/package.json b/packages/@azure/arm-apimanagement/package.json index 0e78f1e608e0..35f9033324b6 100644 --- a/packages/@azure/arm-apimanagement/package.json +++ b/packages/@azure/arm-apimanagement/package.json @@ -4,8 +4,8 @@ "description": "ApiManagementClient Library with typescript type definitions for node.js and browser.", "version": "4.4.0", "dependencies": { - "@azure/ms-rest-azure-js": "^1.1.0", - "@azure/ms-rest-js": "^1.1.0", + "@azure/ms-rest-azure-js": "^1.2.0", + "@azure/ms-rest-js": "^1.2.0", "tslib": "^1.9.3" }, "keywords": [ @@ -23,6 +23,7 @@ "typescript": "^3.1.1", "rollup": "^0.66.2", "rollup-plugin-node-resolve": "^3.4.0", + "rollup-plugin-sourcemaps": "^0.4.2", "uglify-js": "^3.4.9" }, "homepage": "https://github.com/azure/azure-sdk-for-js/tree/master/packages/@azure/arm-apimanagement", @@ -51,6 +52,5 @@ "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/arm-apimanagement.js.map'\" -o ./dist/arm-apimanagement.min.js ./dist/arm-apimanagement.js", "prepack": "npm install && npm run build" }, - "sideEffects": false, - "authPublish": true + "sideEffects": false } diff --git a/packages/@azure/arm-apimanagement/rollup.config.js b/packages/@azure/arm-apimanagement/rollup.config.js index a55a7153ed92..dc0dc5622703 100644 --- a/packages/@azure/arm-apimanagement/rollup.config.js +++ b/packages/@azure/arm-apimanagement/rollup.config.js @@ -1,10 +1,16 @@ +import rollup from "rollup"; import nodeResolve from "rollup-plugin-node-resolve"; +import sourcemaps from "rollup-plugin-sourcemaps"; + /** - * @type {import('rollup').RollupFileOptions} + * @type {rollup.RollupFileOptions} */ const config = { - input: './esm/apiManagementClient.js', - external: ["@azure/ms-rest-js", "@azure/ms-rest-azure-js"], + input: "./esm/apiManagementClient.js", + external: [ + "@azure/ms-rest-js", + "@azure/ms-rest-azure-js" + ], output: { file: "./dist/arm-apimanagement.js", format: "umd", @@ -16,16 +22,16 @@ const config = { }, banner: `/* * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * 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. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. */` }, plugins: [ - nodeResolve({ module: true }) + nodeResolve({ module: true }), + sourcemaps() ] }; + export default config;