diff --git a/sdk/cdn/arm-cdn/LICENSE.txt b/sdk/cdn/arm-cdn/LICENSE.txt index ea8fb1516028..2d3163745319 100644 --- a/sdk/cdn/arm-cdn/LICENSE.txt +++ b/sdk/cdn/arm-cdn/LICENSE.txt @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2020 Microsoft +Copyright (c) 2021 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/sdk/cdn/arm-cdn/README.md b/sdk/cdn/arm-cdn/README.md index 52e45367f756..13649501d41b 100644 --- a/sdk/cdn/arm-cdn/README.md +++ b/sdk/cdn/arm-cdn/README.md @@ -1,11 +1,11 @@ ## Azure CdnManagementClient SDK for JavaScript -This package contains an isomorphic SDK (runs both in Node.js and in browsers) for CdnManagementClient. +This package contains an isomorphic SDK (runs both in node.js and in browsers) for CdnManagementClient. ### Currently supported environments - [LTS versions of Node.js](https://nodejs.org/about/releases/) -- Latest versions of Safari, Chrome, Edge, and Firefox. +- Latest versions of Safari, Chrome, Edge and Firefox. ### Prerequisites @@ -21,7 +21,6 @@ Install both packages using the below command: ```bash npm install --save @azure/arm-cdn @azure/identity ``` - > **Note**: You may have used either `@azure/ms-rest-nodeauth` or `@azure/ms-rest-browserauth` in the past. These packages are in maintenance mode receiving critical bug fixes, but no new features. If you are on a [Node.js that has LTS status](https://nodejs.org/about/releases/), or are writing a client side browser application, we strongly encourage you to upgrade to `@azure/identity` which uses the latest versions of Azure Active Directory and MSAL APIs and provides more authentication options. @@ -37,7 +36,6 @@ If you are on a [Node.js that has LTS status](https://nodejs.org/about/releases/ In the below samples, we pass the credential and the Azure subscription id to instantiate the client. Once the client is created, explore the operations on it either in your favorite editor or in our [API reference documentation](https://docs.microsoft.com/javascript/api) to get started. - #### nodejs - Authentication, client creation, and list profiles as an example written in JavaScript. ##### Sample code @@ -51,7 +49,6 @@ const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"]; // Please note that you can also use credentials from the `@azure/ms-rest-nodeauth` package instead. const creds = new DefaultAzureCredential(); const client = new CdnManagementClient(creds, subscriptionId); - client.profiles.list().then((result) => { console.log("The result is:"); console.log(result); @@ -86,7 +83,7 @@ In browser applications, we recommend using the `InteractiveBrowserCredential` t const credential = new InteractiveBrowserCredential( { clientId: "", - tenantId: "" + tenant: "" }); const client = new Azure.ArmCdn.CdnManagementClient(creds, subscriptionId); client.profiles.list().then((result) => { diff --git a/sdk/cdn/arm-cdn/package.json b/sdk/cdn/arm-cdn/package.json index 5cb098cffa95..5bb101d0d907 100644 --- a/sdk/cdn/arm-cdn/package.json +++ b/sdk/cdn/arm-cdn/package.json @@ -27,7 +27,7 @@ "rollup-plugin-sourcemaps": "^0.4.2", "uglify-js": "^3.6.0" }, - "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/feature/v4/sdk/cdn/arm-cdn", + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/cdn/arm-cdn", "repository": { "type": "git", "url": "https://github.com/Azure/azure-sdk-for-js.git" diff --git a/sdk/cdn/arm-cdn/rollup.config.js b/sdk/cdn/arm-cdn/rollup.config.js index 66576ced5732..d328a5b38b8e 100644 --- a/sdk/cdn/arm-cdn/rollup.config.js +++ b/sdk/cdn/arm-cdn/rollup.config.js @@ -21,8 +21,8 @@ const config = { "@azure/ms-rest-azure-js": "msRestAzure" }, banner: `/* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. diff --git a/sdk/cdn/arm-cdn/src/cdnManagementClient.ts b/sdk/cdn/arm-cdn/src/cdnManagementClient.ts index bb34c2fcd2af..3db4c38ce1bb 100644 --- a/sdk/cdn/arm-cdn/src/cdnManagementClient.ts +++ b/sdk/cdn/arm-cdn/src/cdnManagementClient.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -27,6 +26,18 @@ class CdnManagementClient extends CdnManagementClientContext { resourceUsage: operations.ResourceUsageOperations; operations: operations.Operations; edgeNodes: operations.EdgeNodes; + aFDProfiles: operations.AFDProfiles; + aFDCustomDomains: operations.AFDCustomDomains; + aFDEndpoints: operations.AFDEndpoints; + aFDOriginGroups: operations.AFDOriginGroups; + aFDOrigins: operations.AFDOrigins; + routes: operations.Routes; + ruleSets: operations.RuleSets; + rules: operations.Rules; + securityPolicies: operations.SecurityPolicies; + secrets: operations.Secrets; + validate: operations.Validate; + logAnalytics: operations.LogAnalytics; policies: operations.Policies; managedRuleSets: operations.ManagedRuleSets; @@ -51,6 +62,18 @@ class CdnManagementClient extends CdnManagementClientContext { this.resourceUsage = new operations.ResourceUsageOperations(this); this.operations = new operations.Operations(this); this.edgeNodes = new operations.EdgeNodes(this); + this.aFDProfiles = new operations.AFDProfiles(this); + this.aFDCustomDomains = new operations.AFDCustomDomains(this); + this.aFDEndpoints = new operations.AFDEndpoints(this); + this.aFDOriginGroups = new operations.AFDOriginGroups(this); + this.aFDOrigins = new operations.AFDOrigins(this); + this.routes = new operations.Routes(this); + this.ruleSets = new operations.RuleSets(this); + this.rules = new operations.Rules(this); + this.securityPolicies = new operations.SecurityPolicies(this); + this.secrets = new operations.Secrets(this); + this.validate = new operations.Validate(this); + this.logAnalytics = new operations.LogAnalytics(this); this.policies = new operations.Policies(this); this.managedRuleSets = new operations.ManagedRuleSets(this); } diff --git a/sdk/cdn/arm-cdn/src/cdnManagementClientContext.ts b/sdk/cdn/arm-cdn/src/cdnManagementClientContext.ts index e1ea617ece16..350c4684881a 100644 --- a/sdk/cdn/arm-cdn/src/cdnManagementClientContext.ts +++ b/sdk/cdn/arm-cdn/src/cdnManagementClientContext.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -10,8 +9,8 @@ import * as Models from "./models"; import * as msRest from "@azure/ms-rest-js"; -import { TokenCredential } from "@azure/core-auth"; import * as msRestAzure from "@azure/ms-rest-azure-js"; +import { TokenCredential } from "@azure/core-auth"; const packageName = "@azure/arm-cdn"; const packageVersion = "5.3.1"; @@ -50,7 +49,7 @@ export class CdnManagementClientContext extends msRestAzure.AzureServiceClient { super(credentials, options); - this.apiVersion = '2020-04-15'; + this.apiVersion = '2020-09-01'; this.acceptLanguage = 'en-US'; this.longRunningOperationRetryTimeout = 30; this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com"; diff --git a/sdk/cdn/arm-cdn/src/models/aFDCustomDomainsMappers.ts b/sdk/cdn/arm-cdn/src/models/aFDCustomDomainsMappers.ts new file mode 100644 index 000000000000..0305edefce66 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/aFDCustomDomainsMappers.ts @@ -0,0 +1,135 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDDomainListResult, + AFDDomainUpdateParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters, + ValidationToken +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/aFDEndpointsMappers.ts b/sdk/cdn/arm-cdn/src/models/aFDEndpointsMappers.ts new file mode 100644 index 000000000000..0d9a92437d88 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/aFDEndpointsMappers.ts @@ -0,0 +1,139 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointListResult, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + AfdPurgeParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + Usage, + UsageName, + UsagesListResult, + UserManagedHttpsParameters, + ValidateCustomDomainInput, + ValidateCustomDomainOutput +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/aFDOriginGroupsMappers.ts b/sdk/cdn/arm-cdn/src/models/aFDOriginGroupsMappers.ts new file mode 100644 index 000000000000..14eec650aae6 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/aFDOriginGroupsMappers.ts @@ -0,0 +1,136 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupListResult, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + Usage, + UsageName, + UsagesListResult, + UserManagedHttpsParameters +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/aFDOriginsMappers.ts b/sdk/cdn/arm-cdn/src/models/aFDOriginsMappers.ts new file mode 100644 index 000000000000..a2763e45cfcd --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/aFDOriginsMappers.ts @@ -0,0 +1,133 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginListResult, + AFDOriginUpdateParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/aFDProfilesMappers.ts b/sdk/cdn/arm-cdn/src/models/aFDProfilesMappers.ts new file mode 100644 index 000000000000..1ea386178149 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/aFDProfilesMappers.ts @@ -0,0 +1,18 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AfdErrorResponse, + ErrorResponse, + Usage, + UsageName, + UsagesListResult, + ValidateCustomDomainInput, + ValidateCustomDomainOutput +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/customDomainsMappers.ts b/sdk/cdn/arm-cdn/src/models/customDomainsMappers.ts index 257a7be53000..22ef91a41fa9 100644 --- a/sdk/cdn/arm-cdn/src/models/customDomainsMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/customDomainsMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,6 +8,14 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, @@ -22,6 +30,7 @@ export { CustomDomainHttpsParameters, CustomDomainListResult, CustomDomainParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -47,6 +56,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, Endpoint, EndpointPropertiesUpdateParametersDeliveryPolicy, @@ -62,6 +72,8 @@ export { IsDeviceMatchConditionParameters, KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -72,6 +84,8 @@ export { MatchCondition, Origin, OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginUpdateParameters, PolicySettings, @@ -91,7 +105,17 @@ export { Resource, ResourceReference, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -103,6 +127,7 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, + UrlSigningKeyParameters, UrlSigningParamIdentifier, UserManagedHttpsParameters } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/edgeNodesMappers.ts b/sdk/cdn/arm-cdn/src/models/edgeNodesMappers.ts index 0f3b03a53381..64b47333aec1 100644 --- a/sdk/cdn/arm-cdn/src/models/edgeNodesMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/edgeNodesMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,15 +8,27 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, CdnEndpoint, + CdnManagedHttpsParameters, CdnWebApplicationFirewallPolicy, CdnWebApplicationFirewallPolicyPatchParameters, CidrIpAddress, CookiesMatchConditionParameters, CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -42,6 +54,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, EdgenodeResult, Endpoint, @@ -56,7 +69,10 @@ export { HttpVersionMatchConditionParameters, IpAddressGroup, IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -67,6 +83,8 @@ export { MatchCondition, Origin, OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginUpdateParameters, PolicySettings, @@ -86,7 +104,17 @@ export { Resource, ResourceReference, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -98,5 +126,7 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, - UrlSigningParamIdentifier + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/endpointsMappers.ts b/sdk/cdn/arm-cdn/src/models/endpointsMappers.ts index 4119b833703b..9df98ba651e6 100644 --- a/sdk/cdn/arm-cdn/src/models/endpointsMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/endpointsMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,15 +8,27 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, CdnEndpoint, + CdnManagedHttpsParameters, CdnWebApplicationFirewallPolicy, CdnWebApplicationFirewallPolicyPatchParameters, CidrIpAddress, CookiesMatchConditionParameters, CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -42,6 +54,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, Endpoint, EndpointListResult, @@ -56,8 +69,11 @@ export { HttpVersionMatchConditionParameters, IpAddressGroup, IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, LoadParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -68,6 +84,8 @@ export { MatchCondition, Origin, OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginUpdateParameters, PolicySettings, @@ -90,7 +108,17 @@ export { ResourceUsage, ResourceUsageListResult, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -102,7 +130,9 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, + UrlSigningKeyParameters, UrlSigningParamIdentifier, + UserManagedHttpsParameters, ValidateCustomDomainInput, ValidateCustomDomainOutput } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/index.ts b/sdk/cdn/arm-cdn/src/models/index.ts index b37a0f1f4808..5fefec7eb65d 100644 --- a/sdk/cdn/arm-cdn/src/models/index.ts +++ b/sdk/cdn/arm-cdn/src/models/index.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -18,7 +18,9 @@ export interface Sku { /** * Name of the pricing tier. Possible values include: 'Standard_Verizon', 'Premium_Verizon', * 'Custom_Verizon', 'Standard_Akamai', 'Standard_ChinaCdn', 'Standard_Microsoft', - * 'Premium_ChinaCdn' + * 'Premium_ChinaCdn', 'Standard_AzureFrontDoor', 'Premium_AzureFrontDoor', + * 'Standard_955BandWidth_ChinaCdn', 'Standard_AvgBandWidth_ChinaCdn', 'StandardPlus_ChinaCdn', + * 'StandardPlus_955BandWidth_ChinaCdn', 'StandardPlus_AvgBandWidth_ChinaCdn' */ name?: SkuName; } @@ -42,6 +44,10 @@ export interface Resource extends BaseResource { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly type?: string; + /** + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly systemData?: SystemData; } /** @@ -78,6 +84,11 @@ export interface Profile extends TrackedResource { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly provisioningState?: string; + /** + * The Id of the frontdoor. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly frontdoorId?: string; } /** @@ -458,7 +469,7 @@ export interface DeliveryRuleCondition { /** * Contains the possible cases for DeliveryRuleAction. */ -export type DeliveryRuleActionUnion = DeliveryRuleAction | UrlRedirectAction | UrlSigningAction | UrlRewriteAction | DeliveryRuleRequestHeaderAction | DeliveryRuleResponseHeaderAction | DeliveryRuleCacheExpirationAction | DeliveryRuleCacheKeyQueryStringAction; +export type DeliveryRuleActionUnion = DeliveryRuleAction | UrlRedirectAction | UrlSigningAction | OriginGroupOverrideAction | UrlRewriteAction | DeliveryRuleRequestHeaderAction | DeliveryRuleResponseHeaderAction | DeliveryRuleCacheExpirationAction | DeliveryRuleCacheKeyQueryStringAction; /** * An action for the delivery rule. @@ -676,7 +687,8 @@ export interface DeliveryRuleRequestMethodCondition { export interface QueryStringMatchConditionParameters { /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: QueryStringOperator; /** @@ -717,7 +729,8 @@ export interface PostArgsMatchConditionParameters { selector?: string; /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: PostArgsOperator; /** @@ -754,7 +767,8 @@ export interface DeliveryRulePostArgsCondition { export interface RequestUriMatchConditionParameters { /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: RequestUriOperator; /** @@ -795,7 +809,8 @@ export interface RequestHeaderMatchConditionParameters { selector?: string; /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: RequestHeaderOperator; /** @@ -832,7 +847,8 @@ export interface DeliveryRuleRequestHeaderCondition { export interface RequestBodyMatchConditionParameters { /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: RequestBodyOperator; /** @@ -898,7 +914,7 @@ export interface UrlPathMatchConditionParameters { /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', - * 'Wildcard' + * 'Wildcard', 'RegEx' */ operator: UrlPathOperator; /** @@ -935,7 +951,8 @@ export interface DeliveryRuleUrlPathCondition { export interface UrlFileExtensionMatchConditionParameters { /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: UrlFileExtensionOperator; /** @@ -972,7 +989,8 @@ export interface DeliveryRuleUrlFileExtensionCondition { export interface UrlFileNameMatchConditionParameters { /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: UrlFileNameOperator; /** @@ -1041,7 +1059,8 @@ export interface CookiesMatchConditionParameters { selector?: string; /** * Describes operator to be matched. Possible values include: 'Any', 'Equal', 'Contains', - * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' + * 'BeginsWith', 'EndsWith', 'LessThan', 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', + * 'RegEx' */ operator: CookiesOperator; /** @@ -1173,14 +1192,6 @@ export interface UrlSigningParamIdentifier { * Defines the parameters for the Url Signing action. */ export interface UrlSigningActionParameters { - /** - * Possible values include: '#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlSigningActionParameters' - */ - odatatype?: Odatatype; - /** - * Id reference of the key to be used to verify the hash and should be defined in UrlSigningKeys - */ - keyId: string; /** * Algorithm to use for URL signing. Possible values include: 'SHA256' */ @@ -1189,10 +1200,6 @@ export interface UrlSigningActionParameters { * Defines which query string parameters in the url to be considered for expires, key id etc. */ parameterNameOverride?: UrlSigningParamIdentifier[]; - /** - * Match values to match against. Supports CIDR ranges (both IPv4 and IPv6). - */ - ipSubnets?: string[]; } /** @@ -1209,6 +1216,30 @@ export interface UrlSigningAction { parameters: UrlSigningActionParameters; } +/** + * Defines the parameters for the origin group override action. + */ +export interface OriginGroupOverrideActionParameters { + /** + * defines the OriginGroup that would override the DefaultOriginGroup. + */ + originGroup: ResourceReference; +} + +/** + * Defines the origin group override action for the delivery rule. + */ +export interface OriginGroupOverrideAction { + /** + * Polymorphic Discriminator + */ + name: "OriginGroupOverride"; + /** + * Defines the parameters for the action. + */ + parameters: OriginGroupOverrideActionParameters; +} + /** * Defines the parameters for the url rewrite action. */ @@ -1568,6 +1599,31 @@ export interface OriginGroupUpdateParameters extends BaseResource { responseBasedOriginErrorDetectionSettings?: ResponseBasedOriginErrorDetectionParameters; } +/** + * Contains the possible cases for CustomDomainHttpsParameters. + */ +export type CustomDomainHttpsParametersUnion = CustomDomainHttpsParameters | CdnManagedHttpsParameters | UserManagedHttpsParameters; + +/** + * The JSON object that contains the properties to secure a custom domain. + */ +export interface CustomDomainHttpsParameters { + /** + * Polymorphic Discriminator + */ + certificateSource: "CustomDomainHttpsParameters"; + /** + * Defines the TLS extension protocol that is used for secure delivery. Possible values include: + * 'ServerNameIndication', 'IPBased' + */ + protocolType: ProtocolType; + /** + * TLS protocol version that will be used for Https. Possible values include: 'None', 'TLS10', + * 'TLS12' + */ + minimumTlsVersion?: MinimumTlsVersion; +} + /** * Friendly domain name mapping to the endpoint hostname that the customer provides for branding * purposes, e.g. www.contoso.com. @@ -1599,6 +1655,10 @@ export interface CustomDomain extends ProxyResource { * **NOTE: This property will not be serialized. It can only be populated by the server.** */ readonly customHttpsProvisioningSubstate?: CustomHttpsProvisioningSubstate; + /** + * Certificate parameters for securing custom HTTPS + */ + customHttpsParameters?: CustomDomainHttpsParametersUnion; /** * Special validation or data may be required when delivering CDN to some regions due to local * compliance reasons. E.g. ICP license number of a custom domain is required to deliver content @@ -1622,31 +1682,6 @@ export interface CustomDomainParameters { hostName: string; } -/** - * Contains the possible cases for CustomDomainHttpsParameters. - */ -export type CustomDomainHttpsParametersUnion = CustomDomainHttpsParameters | CdnManagedHttpsParameters | UserManagedHttpsParameters; - -/** - * The JSON object that contains the properties to secure a custom domain. - */ -export interface CustomDomainHttpsParameters { - /** - * Polymorphic Discriminator - */ - certificateSource: "CustomDomainHttpsParameters"; - /** - * Defines the TLS extension protocol that is used for secure delivery. Possible values include: - * 'ServerNameIndication', 'IPBased' - */ - protocolType: ProtocolType; - /** - * TLS protocol version that will be used for Https. Possible values include: 'None', 'TLS10', - * 'TLS12' - */ - minimumTlsVersion?: MinimumTlsVersion; -} - /** * Defines the parameters for using CDN managed certificate for securing custom domain. */ @@ -1928,6 +1963,38 @@ export interface EdgeNode extends ProxyResource { ipAddressGroups: IpAddressGroup[]; } +/** + * Read only system data + */ +export interface SystemData { + /** + * An identifier for the identity that created the resource + */ + createdBy?: string; + /** + * The type of identity that created the resource. Possible values include: 'user', + * 'application', 'managedIdentity', 'key' + */ + createdByType?: IdentityType; + /** + * The timestamp of resource creation (UTC) + */ + createdAt?: Date; + /** + * An identifier for the identity that last modified the resource + */ + lastModifiedBy?: string; + /** + * The type of identity that last modified the resource. Possible values include: 'user', + * 'application', 'managedIdentity', 'key' + */ + lastModifiedByType?: IdentityType; + /** + * The timestamp of resource last modification (UTC) + */ + lastModifiedAt?: Date; +} + /** * Error response indicates CDN service is not able to process the incoming request. The reason is * provided in the error message. @@ -1946,928 +2013,4238 @@ export interface ErrorResponse { } /** - * Defines contents of a web application firewall global configuration + * Parameters required for content purge. */ -export interface PolicySettings { +export interface AfdPurgeParameters { /** - * describes if the policy is in enabled state or disabled state. Possible values include: - * 'Disabled', 'Enabled' + * The path to the content to be purged. Can describe a file path or a wild card directory. */ - enabledState?: PolicyEnabledState; + contentPaths: string[]; /** - * Describes if it is in detection mode or prevention mode at policy level. Possible values - * include: 'Prevention', 'Detection' + * List of domains. */ - mode?: PolicyMode; + domains?: string[]; +} + +/** + * Certificate used for https + */ +export interface Certificate { /** - * If action type is redirect, this field represents the default redirect URL for the client. + * Subject name in the certificate. */ - defaultRedirectUrl?: string; + subject?: string; /** - * If the action type is block, this field defines the default customer overridable http response - * status code. + * Certificate expiration date. */ - defaultCustomBlockResponseStatusCode?: number; + expirationDate?: string; /** - * If the action type is block, customer can override the response body. The body must be - * specified in base64 encoding. + * Certificate thumbprint. */ - defaultCustomBlockResponseBody?: string; + thumbprint?: string; } /** - * Defines the common attributes for a custom rule that can be included in a waf policy + * Managed Certificate used for https */ -export interface CustomRule { +export interface ManagedCertificate extends Certificate { +} + +/** + * Customer Certificate used for https + */ +export interface CustomerCertificate extends Certificate { /** - * Defines the name of the custom rule + * Certificate version. */ - name: string; + version?: string; /** - * Describes if the custom rule is in enabled or disabled state. Defaults to Enabled if not - * specified. Possible values include: 'Disabled', 'Enabled' + * Certificate issuing authority. */ - enabledState?: CustomRuleEnabledState; + certificateAuthority?: string; /** - * Defines in what order this rule be evaluated in the overall list of custom rules + * Complete Url to the certificate */ - priority: number; + certificateUrl: string; /** - * List of match conditions. + * Whether to use the latest version for the certificate */ - matchConditions: MatchCondition[]; + useLatestVersion?: boolean; /** - * Describes what action to be applied when rule matches. Possible values include: 'Allow', - * 'Block', 'Log', 'Redirect' + * The list of SANs. */ - action: ActionType; + subjectAlternativeNames?: string[]; } /** - * Defines a rate limiting rule that can be included in a waf policy + * Input of the secret to be validated. */ -export interface RateLimitRule extends CustomRule { +export interface ValidateSecretInput { /** - * Defines rate limit threshold. + * The secret source. */ - rateLimitThreshold: number; + secretSource: ResourceReference; /** - * Defines rate limit duration. Default is 1 minute. + * The secret type. Possible values include: 'UrlSigningKey', 'ManagedCertificate', + * 'CustomerCertificate' */ - rateLimitDurationInMinutes: number; + secretType: ValidateSecretType; } /** - * Defines contents of rate limit rules + * Output of the validated secret. */ -export interface RateLimitRuleList { +export interface ValidateSecretOutput { /** - * List of rules + * The validation status. Possible values include: 'Valid', 'Invalid', 'AccessDenied', + * 'CertificateExpired' */ - rules?: RateLimitRule[]; + status?: Status; + /** + * Detailed error message + */ + message?: string; } /** - * Define match conditions + * The JSON object that contains the properties to secure a domain. */ -export interface MatchCondition { +export interface AFDDomainHttpsParameters { /** - * Match variable to compare against. Possible values include: 'RemoteAddr', 'SocketAddr', - * 'RequestMethod', 'RequestHeader', 'RequestUri', 'QueryString', 'RequestBody', 'Cookies', - * 'PostArgs' - */ - matchVariable: MatchVariable; - /** - * Selector can used to match a specific key for QueryString, Cookies, RequestHeader or PostArgs. - */ - selector?: string; - /** - * Describes operator to be matched. Possible values include: 'Any', 'IPMatch', 'GeoMatch', - * 'Equal', 'Contains', 'LessThan', 'GreaterThan', 'LessThanOrEqual', 'GreaterThanOrEqual', - * 'BeginsWith', 'EndsWith', 'RegEx' - */ - operator: Operator; - /** - * Describes if the result of this condition should be negated. + * Defines the source of the SSL certificate. Possible values include: 'CustomerCertificate', + * 'ManagedCertificate' */ - negateCondition?: boolean; + certificateType: AfdCertificateType; /** - * List of possible match values. + * TLS protocol version that will be used for Https. Possible values include: 'TLS10', 'TLS12' */ - matchValue: string[]; + minimumTlsVersion?: AfdMinimumTlsVersion; /** - * List of transforms. + * Resource reference to the secret. ie. subs/rg/profile/secret */ - transforms?: TransformType[]; + secret?: ResourceReference; } /** - * Defines contents of custom rules + * The JSON object that contains the properties to validate a domain. */ -export interface CustomRuleList { +export interface DomainValidationProperties { /** - * List of rules + * Challenge used for DNS TXT record or file based validation + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - rules?: CustomRule[]; + readonly validationToken?: string; + /** + * The date time that the token expires + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly expirationDate?: string; } /** - * Defines a managed rule group override setting. + * Friendly domain name mapping to the endpoint hostname that the customer provides for branding + * purposes, e.g. www.contoso.com. */ -export interface ManagedRuleOverride { +export interface AFDDomain extends ProxyResource { /** - * Identifier for the managed rule. + * The configuration specifying how to enable HTTPS for the domain - using AzureFrontDoor managed + * certificate or user's own certificate. If not specified, enabling ssl uses AzureFrontDoor + * managed certificate by default. */ - ruleId: string; + tlsSettings?: AFDDomainHttpsParameters; /** - * Describes if the managed rule is in enabled or disabled state. Defaults to Disabled if not - * specified. Possible values include: 'Disabled', 'Enabled' + * Resource reference to the Azure DNS zone */ - enabledState?: ManagedRuleEnabledState; + azureDnsZone?: ResourceReference; /** - * Describes the override action to be applied when rule matches. Possible values include: - * 'Allow', 'Block', 'Log', 'Redirect' + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - action?: ActionType; + readonly provisioningState?: AfdProvisioningState; + /** + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deploymentStatus?: DeploymentStatus; + /** + * Provisioning substate shows the progress of custom HTTPS enabling/disabling process step by + * step. DCV stands for DomainControlValidation. Possible values include: 'Unknown', + * 'Submitting', 'Pending', 'TimedOut', 'PendingRevalidation', 'Approved' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly domainValidationState?: DomainValidationState; + /** + * The host name of the domain. Must be a domain name. + */ + hostName: string; + /** + * Values the customer needs to validate domain ownership + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly validationProperties?: DomainValidationProperties; } /** - * Defines a managed rule group override setting. + * The domain JSON object required for domain creation or update. */ -export interface ManagedRuleGroupOverride { +export interface AFDDomainUpdateParameters { /** - * Describes the managed rule group within the rule set to override + * The configuration specifying how to enable HTTPS for the domain - using AzureFrontDoor managed + * certificate or user's own certificate. If not specified, enabling ssl uses AzureFrontDoor + * managed certificate by default. */ - ruleGroupName: string; + tlsSettings?: AFDDomainHttpsParameters; /** - * List of rules that will be disabled. If none specified, all rules in the group will be - * disabled. + * Resource reference to the Azure DNS zone */ - rules?: ManagedRuleOverride[]; + azureDnsZone?: ResourceReference; } /** - * Defines a managed rule set. + * Contains the possible cases for SecurityPolicyParameters. */ -export interface ManagedRuleSet { - /** - * Defines the rule set type to use. - */ - ruleSetType: string; +export type SecurityPolicyParametersUnion = SecurityPolicyParameters | SecurityPolicyWebApplicationFirewallParameters; + +/** + * The json object containing security policy parameters + */ +export interface SecurityPolicyParameters { /** - * Defines the version of the rule set to use. + * Polymorphic Discriminator */ - ruleSetVersion: string; + type: "SecurityPolicyParameters"; +} + +/** + * The tracking states for afd resources. + */ +export interface AFDStateProperties { /** - * Verizon only : If the rule set supports anomaly detection mode, this describes the threshold - * for blocking requests. + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - anomalyScore?: number; + readonly provisioningState?: AfdProvisioningState; /** - * Defines the rule overrides to apply to the rule set. + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - ruleGroupOverrides?: ManagedRuleGroupOverride[]; + readonly deploymentStatus?: DeploymentStatus; } /** - * Defines the list of managed rule sets for the policy. + * The json object that contains properties required to create a security policy */ -export interface ManagedRuleSetList { +export interface SecurityPolicyProperties extends AFDStateProperties { /** - * List of rule sets. + * object which contains security policy parameters */ - managedRuleSets?: ManagedRuleSet[]; + parameters?: SecurityPolicyParametersUnion; } /** - * Defines the ARM Resource ID for the linked endpoints + * SecurityPolicy association for AzureFrontDoor profile */ -export interface CdnEndpoint { +export interface SecurityPolicy extends ProxyResource { /** - * ARM Resource ID string. + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - id?: string; -} - -/** - * Defines web application firewall policy for Azure CDN. - */ -export interface CdnWebApplicationFirewallPolicy extends TrackedResource { - /** - * Describes policySettings for policy - */ - policySettings?: PolicySettings; - /** - * Describes rate limit rules inside the policy. - */ - rateLimitRules?: RateLimitRuleList; - /** - * Describes custom rules inside the policy. - */ - customRules?: CustomRuleList; - /** - * Describes managed rules inside the policy. - */ - managedRules?: ManagedRuleSetList; - /** - * Describes Azure CDN endpoints associated with this Web Application Firewall policy. - * **NOTE: This property will not be serialized. It can only be populated by the server.** - */ - readonly endpointLinks?: CdnEndpoint[]; - /** - * Provisioning state of the WebApplicationFirewallPolicy. Possible values include: 'Creating', - * 'Succeeded', 'Failed' - * **NOTE: This property will not be serialized. It can only be populated by the server.** - */ - readonly provisioningState?: ProvisioningState; + readonly provisioningState?: AfdProvisioningState; /** - * Resource status of the policy. Possible values include: 'Creating', 'Enabling', 'Enabled', - * 'Disabling', 'Disabled', 'Deleting' + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - readonly resourceState?: PolicyResourceState; - /** - * Gets a unique read-only string that changes whenever the resource is updated. - */ - etag?: string; - /** - * The pricing tier (defines a CDN provider, feature list and rate) of the - * CdnWebApplicationFirewallPolicy. - */ - sku: Sku; -} - -/** - * Properties required to update a CdnWebApplicationFirewallPolicy. - */ -export interface CdnWebApplicationFirewallPolicyPatchParameters extends BaseResource { + readonly deploymentStatus?: DeploymentStatus; /** - * CdnWebApplicationFirewallPolicy tags + * object which contains security policy parameters */ - tags?: { [propertyName: string]: string }; + parameters?: SecurityPolicyParametersUnion; } /** - * Describes a managed rule definition. + * settings for security policy patterns to match */ -export interface ManagedRuleDefinition { +export interface SecurityPolicyWebApplicationFirewallAssociation { /** - * Identifier for the managed rule. - * **NOTE: This property will not be serialized. It can only be populated by the server.** + * List of domains. */ - readonly ruleId?: string; + domains?: ResourceReference[]; /** - * Describes the functionality of the managed rule. - * **NOTE: This property will not be serialized. It can only be populated by the server.** + * List of paths */ - readonly description?: string; + patternsToMatch?: string[]; } /** - * Describes a managed rule group. + * The json object containing security policy waf parameters */ -export interface ManagedRuleGroupDefinition { +export interface SecurityPolicyWebApplicationFirewallParameters { /** - * Name of the managed rule group. - * **NOTE: This property will not be serialized. It can only be populated by the server.** + * Polymorphic Discriminator */ - readonly ruleGroupName?: string; + type: "WebApplicationFirewall"; /** - * Description of the managed rule group. - * **NOTE: This property will not be serialized. It can only be populated by the server.** + * Resource ID. */ - readonly description?: string; + wafPolicy?: ResourceReference; /** - * List of rules within the managed rule group. - * **NOTE: This property will not be serialized. It can only be populated by the server.** + * Waf associations */ - readonly rules?: ManagedRuleDefinition[]; + associations?: SecurityPolicyWebApplicationFirewallAssociation[]; } /** - * Describes a managed rule set definition. + * CDN endpoint is the entity within a CDN profile containing configuration information such as + * origin, protocol, content caching and delivery behavior. The AzureFrontDoor endpoint uses the + * URL format .azureedge.net. */ -export interface ManagedRuleSetDefinition extends Resource { +export interface AFDEndpoint extends TrackedResource { /** - * Provisioning state of the managed rule set. - * **NOTE: This property will not be serialized. It can only be populated by the server.** + * Send and receive timeout on forwarding request to the origin. When timeout is reached, the + * request fails and returns. */ - readonly provisioningState?: string; + originResponseTimeoutSeconds?: number; /** - * Type of the managed rule set. - * **NOTE: This property will not be serialized. It can only be populated by the server.** + * Whether to enable use of this rule. Permitted values are 'Enabled' or 'Disabled'. Possible + * values include: 'Enabled', 'Disabled' */ - readonly ruleSetType?: string; + enabledState?: EnabledState; /** - * Version of the managed rule set type. + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - readonly ruleSetVersion?: string; + readonly provisioningState?: AfdProvisioningState; /** - * Rule groups of the managed rule set. + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - readonly ruleGroups?: ManagedRuleGroupDefinition[]; + readonly deploymentStatus?: DeploymentStatus; /** - * The pricing tier (defines a CDN provider, feature list and rate) of the - * CdnWebApplicationFirewallPolicy. + * The host name of the endpoint structured as {endpointName}.{DNSZone}, e.g. + * contoso.azureedge.net + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - sku?: Sku; + readonly hostName?: string; } /** - * Optional Parameters. + * Properties required to create or update an endpoint. */ -export interface ProfilesUpdateOptionalParams extends msRest.RequestOptionsBase { +export interface AFDEndpointUpdateParameters extends BaseResource { /** - * Profile tags + * Endpoint tags. */ tags?: { [propertyName: string]: string }; -} - -/** - * Optional Parameters. - */ -export interface ProfilesBeginUpdateOptionalParams extends msRest.RequestOptionsBase { /** - * Profile tags + * Send and receive timeout on forwarding request to the origin. When timeout is reached, the + * request fails and returns. */ - tags?: { [propertyName: string]: string }; -} - -/** - * Optional Parameters. - */ -export interface CustomDomainsEnableCustomHttpsOptionalParams extends msRest.RequestOptionsBase { + originResponseTimeoutSeconds?: number; /** - * The configuration specifying how to enable HTTPS for the custom domain - using CDN managed - * certificate or user's own certificate. If not specified, enabling ssl uses CDN managed - * certificate by default. + * Whether to enable use of this rule. Permitted values are 'Enabled' or 'Disabled'. Possible + * values include: 'Enabled', 'Disabled' */ - customDomainHttpsParameters?: CustomDomainHttpsParametersUnion; + enabledState?: EnabledState; } /** - * Optional Parameters. + * settings for compression. */ -export interface PoliciesUpdateOptionalParams extends msRest.RequestOptionsBase { +export interface CompressionSettings { /** - * CdnWebApplicationFirewallPolicy tags + * List of content types on which compression applies. The value should be a valid MIME type. */ - tags?: { [propertyName: string]: string }; -} - -/** - * Optional Parameters. - */ -export interface PoliciesBeginUpdateOptionalParams extends msRest.RequestOptionsBase { + contentTypesToCompress?: string[]; /** - * CdnWebApplicationFirewallPolicy tags + * Indicates whether content compression is enabled on AzureFrontDoor. Default value is false. If + * compression is enabled, content will be served as compressed if user requests for a compressed + * version. Content won't be compressed on AzureFrontDoor when requested content is smaller than + * 1 byte or larger than 1 MB. */ - tags?: { [propertyName: string]: string }; + isCompressionEnabled?: boolean; } /** - * An interface representing CdnManagementClientOptions. + * Contains the possible cases for SecretParameters. */ -export interface CdnManagementClientOptions extends AzureServiceClientOptions { - baseUri?: string; -} +export type SecretParametersUnion = SecretParameters | UrlSigningKeyParameters | ManagedCertificateParameters | CustomerCertificateParameters; /** - * @interface - * Result of the request to list profiles. It contains a list of profile objects and a URL link to - * get the next set of results. - * @extends Array + * The json object containing secret parameters */ -export interface ProfileListResult extends Array { +export interface SecretParameters { /** - * URL to get the next set of profile objects if there are any. + * Polymorphic Discriminator */ - nextLink?: string; + type: "SecretParameters"; } /** - * @interface - * Output of check resource usage API. - * @extends Array + * The JSON object that contains the properties of the Secret to create. */ -export interface ResourceUsageListResult extends Array { +export interface SecretProperties extends AFDStateProperties { /** - * URL to get the next set of custom domain objects if there are any. + * object which contains secret parameters */ - nextLink?: string; + parameters?: SecretParametersUnion; } /** - * @interface - * Result of the request to list endpoints. It contains a list of endpoint objects and a URL link - * to get the next set of results. - * @extends Array + * Friendly Secret name mapping to the any Secret or secret related information. */ -export interface EndpointListResult extends Array { +export interface Secret extends ProxyResource { /** - * URL to get the next set of endpoint objects if there is any. + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - nextLink?: string; -} - -/** - * @interface - * Result of the request to list origins. It contains a list of origin objects and a URL link to - * get the next set of results. - * @extends Array - */ -export interface OriginListResult extends Array { + readonly provisioningState?: AfdProvisioningState; /** - * URL to get the next set of origin objects if there are any. + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - nextLink?: string; -} - -/** - * @interface - * Result of the request to list origin groups. It contains a list of origin groups objects and a - * URL link to get the next set of results. - * @extends Array - */ -export interface OriginGroupListResult extends Array { + readonly deploymentStatus?: DeploymentStatus; /** - * URL to get the next set of origin objects if there are any. + * object which contains secret parameters */ - nextLink?: string; + parameters?: SecretParametersUnion; } /** - * @interface - * Result of the request to list custom domains. It contains a list of custom domain objects and a - * URL link to get the next set of results. - * @extends Array + * Url signing key parameters */ -export interface CustomDomainListResult extends Array { +export interface UrlSigningKeyParameters { /** - * URL to get the next set of custom domain objects if there are any. + * Polymorphic Discriminator */ - nextLink?: string; -} - -/** - * @interface - * Result of the request to list CDN operations. It contains a list of operations and a URL link to - * get the next set of results. - * @extends Array - */ -export interface OperationsListResult extends Array { + type: "UrlSigningKey"; /** - * URL to get the next set of operation list results if there are any. + * Defines the customer defined key Id. This id will exist in the incoming request to indicate + * the key used to form the hash. */ - nextLink?: string; + keyId: string; + /** + * Resource reference to the KV secret + */ + secretSource: ResourceReference; + /** + * Version of the secret to be used + */ + secretVersion?: string; } /** - * @interface - * Result of the request to list CDN edgenodes. It contains a list of ip address group and a URL - * link to get the next set of results. - * @extends Array + * Managed Certificate used for https */ -export interface EdgenodeResult extends Array { +export interface ManagedCertificateParameters { /** - * URL to get the next set of edgenode list results if there are any. + * Polymorphic Discriminator */ - nextLink?: string; + type: "ManagedCertificate"; } /** - * @interface - * Defines a list of WebApplicationFirewallPolicies for Azure CDN. It contains a list of - * WebApplicationFirewallPolicy objects and a URL link to get the next set of results. - * @extends Array + * Customer Certificate used for https */ -export interface CdnWebApplicationFirewallPolicyList extends Array { +export interface CustomerCertificateParameters { /** - * URL to get the next set of WebApplicationFirewallPolicy objects if there are any. + * Polymorphic Discriminator */ - nextLink?: string; + type: "CustomerCertificate"; + /** + * Resource reference to the KV secret + */ + secretSource: ResourceReference; + /** + * Version of the secret to be used + */ + secretVersion?: string; + /** + * Certificate issuing authority. + */ + certificateAuthority?: string; + /** + * Whether to use the latest version for the certificate + */ + useLatestVersion?: boolean; + /** + * The list of SANs. + */ + subjectAlternativeNames?: string[]; } /** - * @interface - * List of managed rule set definitions available for use in a policy. - * @extends Array + * Friendly RuleSet name mapping to the any RuleSet or secret related information. */ -export interface ManagedRuleSetDefinitionList extends Array { +export interface RuleSet extends ProxyResource { /** - * URL to retrieve next set of managed rule set definitions. + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** */ - nextLink?: string; + readonly provisioningState?: AfdProvisioningState; + /** + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deploymentStatus?: DeploymentStatus; } /** - * Defines values for SkuName. - * Possible values include: 'Standard_Verizon', 'Premium_Verizon', 'Custom_Verizon', - * 'Standard_Akamai', 'Standard_ChinaCdn', 'Standard_Microsoft', 'Premium_ChinaCdn' - * @readonly - * @enum {string} + * CDN origin is the source of the content being delivered via CDN. When the edge nodes represented + * by an endpoint do not have the requested content cached, they attempt to fetch it from one or + * more of the configured origins. */ -export type SkuName = 'Standard_Verizon' | 'Premium_Verizon' | 'Custom_Verizon' | 'Standard_Akamai' | 'Standard_ChinaCdn' | 'Standard_Microsoft' | 'Premium_ChinaCdn'; - -/** - * Defines values for ProfileResourceState. - * Possible values include: 'Creating', 'Active', 'Deleting', 'Disabled' +export interface AFDOrigin extends ProxyResource { + /** + * Resource reference to the Azure origin resource. + */ + azureOrigin?: ResourceReference; + /** + * The address of the origin. Domain names, IPv4 addresses, and IPv6 addresses are supported.This + * should be unique across all origins in an endpoint. + */ + hostName: string; + /** + * The value of the HTTP port. Must be between 1 and 65535. + */ + httpPort?: number; + /** + * The value of the HTTPS port. Must be between 1 and 65535. + */ + httpsPort?: number; + /** + * The host header value sent to the origin with each request. If you leave this blank, the + * request hostname determines this value. Azure CDN origins, such as Web Apps, Blob Storage, and + * Cloud Services require this host header value to match the origin hostname by default. This + * overrides the host header defined at Endpoint + */ + originHostHeader?: string; + /** + * Priority of origin in given origin group for load balancing. Higher priorities will not be + * used for load balancing if any lower priority origin is healthy.Must be between 1 and 5 + */ + priority?: number; + /** + * Weight of the origin in given origin group for load balancing. Must be between 1 and 1000 + */ + weight?: number; + /** + * The properties of the private link resource for private origin. + */ + sharedPrivateLinkResource?: any; + /** + * Whether to enable health probes to be made against backends defined under backendPools. Health + * probes can only be disabled if there is a single enabled backend in single enabled backend + * pool. Possible values include: 'Enabled', 'Disabled' + */ + enabledState?: EnabledState; + /** + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: AfdProvisioningState; + /** + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deploymentStatus?: DeploymentStatus; +} + +/** + * AFDOrigin properties needed for origin update. + */ +export interface AFDOriginUpdateParameters extends BaseResource { + /** + * Resource reference to the Azure origin resource. + */ + azureOrigin?: ResourceReference; + /** + * The address of the origin. Domain names, IPv4 addresses, and IPv6 addresses are supported.This + * should be unique across all origins in an endpoint. + */ + hostName?: string; + /** + * The value of the HTTP port. Must be between 1 and 65535. + */ + httpPort?: number; + /** + * The value of the HTTPS port. Must be between 1 and 65535. + */ + httpsPort?: number; + /** + * The host header value sent to the origin with each request. If you leave this blank, the + * request hostname determines this value. Azure CDN origins, such as Web Apps, Blob Storage, and + * Cloud Services require this host header value to match the origin hostname by default. This + * overrides the host header defined at Endpoint + */ + originHostHeader?: string; + /** + * Priority of origin in given origin group for load balancing. Higher priorities will not be + * used for load balancing if any lower priority origin is healthy.Must be between 1 and 5 + */ + priority?: number; + /** + * Weight of the origin in given origin group for load balancing. Must be between 1 and 1000 + */ + weight?: number; + /** + * The properties of the private link resource for private origin. + */ + sharedPrivateLinkResource?: any; + /** + * Whether to enable health probes to be made against backends defined under backendPools. Health + * probes can only be disabled if there is a single enabled backend in single enabled backend + * pool. Possible values include: 'Enabled', 'Disabled' + */ + enabledState?: EnabledState; +} + +/** + * Describes the properties of an existing Shared Private Link Resource to use when connecting to a + * private origin. + */ +export interface SharedPrivateLinkResourceProperties { + /** + * The resource id of the resource the shared private link resource is for. + */ + privateLink?: ResourceReference; + /** + * The location of the shared private link resource + */ + privateLinkLocation?: string; + /** + * The group id from the provider of resource the shared private link resource is for. + */ + groupId?: string; + /** + * The request message for requesting approval of the shared private link resource. + */ + requestMessage?: string; + /** + * Status of the shared private link resource. Can be Pending, Approved, Rejected, Disconnected, + * or Timeout. Possible values include: 'Pending', 'Approved', 'Rejected', 'Disconnected', + * 'Timeout' + */ + status?: SharedPrivateLinkResourceStatus; +} + +/** + * Round-Robin load balancing settings for a backend pool + */ +export interface LoadBalancingSettingsParameters { + /** + * The number of samples to consider for load balancing decisions + */ + sampleSize?: number; + /** + * The number of samples within the sample period that must succeed + */ + successfulSamplesRequired?: number; + /** + * The additional latency in milliseconds for probes to fall into the lowest latency bucket + */ + additionalLatencyInMilliseconds?: number; +} + +/** + * AFDOrigin group comprising of origins is used for load balancing to origins when the content + * cannot be served from CDN. + */ +export interface AFDOriginGroup extends ProxyResource { + /** + * Load balancing settings for a backend pool + */ + loadBalancingSettings?: LoadBalancingSettingsParameters; + /** + * Health probe settings to the origin that is used to determine the health of the origin. + */ + healthProbeSettings?: HealthProbeParameters; + /** + * Time in minutes to shift the traffic to the endpoint gradually when an unhealthy endpoint + * comes healthy or a new endpoint is added. Default is 10 mins. This property is currently not + * supported. + */ + trafficRestorationTimeToHealedOrNewEndpointsInMinutes?: number; + /** + * The JSON object that contains the properties to determine origin health using real + * requests/responses. This property is currently not supported. + */ + responseBasedAfdOriginErrorDetectionSettings?: ResponseBasedOriginErrorDetectionParameters; + /** + * Whether to allow session affinity on this host. Valid options are 'Enabled' or 'Disabled'. + * Possible values include: 'Enabled', 'Disabled' + */ + sessionAffinityState?: EnabledState; + /** + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: AfdProvisioningState; + /** + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deploymentStatus?: DeploymentStatus; +} + +/** + * AFDOrigin group properties needed for origin group creation or update. + */ +export interface AFDOriginGroupUpdateParameters extends BaseResource { + /** + * Load balancing settings for a backend pool + */ + loadBalancingSettings?: LoadBalancingSettingsParameters; + /** + * Health probe settings to the origin that is used to determine the health of the origin. + */ + healthProbeSettings?: HealthProbeParameters; + /** + * Time in minutes to shift the traffic to the endpoint gradually when an unhealthy endpoint + * comes healthy or a new endpoint is added. Default is 10 mins. This property is currently not + * supported. + */ + trafficRestorationTimeToHealedOrNewEndpointsInMinutes?: number; + /** + * The JSON object that contains the properties to determine origin health using real + * requests/responses. This property is currently not supported. + */ + responseBasedAfdOriginErrorDetectionSettings?: ResponseBasedOriginErrorDetectionParameters; + /** + * Whether to allow session affinity on this host. Valid options are 'Enabled' or 'Disabled'. + * Possible values include: 'Enabled', 'Disabled' + */ + sessionAffinityState?: EnabledState; +} + +/** + * Friendly Routes name mapping to the any Routes or secret related information. + */ +export interface Route extends ProxyResource { + /** + * Domains referenced by this endpoint. + */ + customDomains?: ResourceReference[]; + /** + * A reference to the origin group. + */ + originGroup: ResourceReference; + /** + * A directory path on the origin that AzureFrontDoor can use to retrieve content from, e.g. + * contoso.cloudapp.net/originpath. + */ + originPath?: string; + /** + * rule sets referenced by this endpoint. + */ + ruleSets?: ResourceReference[]; + /** + * List of supported protocols for this route. + */ + supportedProtocols?: AFDEndpointProtocols[]; + /** + * The route patterns of the rule. + */ + patternsToMatch?: string[]; + /** + * compression settings. + */ + compressionSettings?: any; + /** + * Defines how CDN caches requests that include query strings. You can ignore any query strings + * when caching, bypass caching to prevent requests that contain query strings from being cached, + * or cache every request with a unique URL. Possible values include: 'IgnoreQueryString', + * 'UseQueryString', 'NotSet' + */ + queryStringCachingBehavior?: AfdQueryStringCachingBehavior; + /** + * Protocol this rule will use when forwarding traffic to backends. Possible values include: + * 'HttpOnly', 'HttpsOnly', 'MatchRequest' + */ + forwardingProtocol?: ForwardingProtocol; + /** + * whether this route will be linked to the default endpoint domain. Possible values include: + * 'Enabled', 'Disabled' + */ + linkToDefaultDomain?: LinkToDefaultDomain; + /** + * Whether to automatically redirect HTTP traffic to HTTPS traffic. Note that this is a easy way + * to set up this rule and it will be the first rule that gets executed. Possible values include: + * 'Enabled', 'Disabled' + */ + httpsRedirect?: HttpsRedirect; + /** + * Whether to enable use of this rule. Permitted values are 'Enabled' or 'Disabled'. Possible + * values include: 'Enabled', 'Disabled' + */ + enabledState?: EnabledState; + /** + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: AfdProvisioningState; + /** + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deploymentStatus?: DeploymentStatus; +} + +/** + * The domain JSON object required for domain creation or update. + */ +export interface RouteUpdateParameters { + /** + * Domains referenced by this endpoint. + */ + customDomains?: ResourceReference[]; + /** + * A reference to the origin group. + */ + originGroup?: ResourceReference; + /** + * A directory path on the origin that AzureFrontDoor can use to retrieve content from, e.g. + * contoso.cloudapp.net/originpath. + */ + originPath?: string; + /** + * rule sets referenced by this endpoint. + */ + ruleSets?: ResourceReference[]; + /** + * List of supported protocols for this route. + */ + supportedProtocols?: AFDEndpointProtocols[]; + /** + * The route patterns of the rule. + */ + patternsToMatch?: string[]; + /** + * compression settings. + */ + compressionSettings?: any; + /** + * Defines how CDN caches requests that include query strings. You can ignore any query strings + * when caching, bypass caching to prevent requests that contain query strings from being cached, + * or cache every request with a unique URL. Possible values include: 'IgnoreQueryString', + * 'UseQueryString', 'NotSet' + */ + queryStringCachingBehavior?: AfdQueryStringCachingBehavior; + /** + * Protocol this rule will use when forwarding traffic to backends. Possible values include: + * 'HttpOnly', 'HttpsOnly', 'MatchRequest' + */ + forwardingProtocol?: ForwardingProtocol; + /** + * whether this route will be linked to the default endpoint domain. Possible values include: + * 'Enabled', 'Disabled' + */ + linkToDefaultDomain?: LinkToDefaultDomain; + /** + * Whether to automatically redirect HTTP traffic to HTTPS traffic. Note that this is a easy way + * to set up this rule and it will be the first rule that gets executed. Possible values include: + * 'Enabled', 'Disabled' + */ + httpsRedirect?: HttpsRedirect; + /** + * Whether to enable use of this rule. Permitted values are 'Enabled' or 'Disabled'. Possible + * values include: 'Enabled', 'Disabled' + */ + enabledState?: EnabledState; +} + +/** + * Friendly Rules name mapping to the any Rules or secret related information. + */ +export interface Rule extends ProxyResource { + /** + * The order in which the rules are applied for the endpoint. Possible values {0,1,2,3,………}. A + * rule with a lesser order will be applied before a rule with a greater order. Rule with order 0 + * is a special rule. It does not require any condition and actions listed in it will always be + * applied. + */ + order: number; + /** + * A list of conditions that must be matched for the actions to be executed + */ + conditions?: DeliveryRuleConditionUnion[]; + /** + * A list of actions that are executed when all the conditions of a rule are satisfied. + */ + actions: DeliveryRuleActionUnion[]; + /** + * If this rule is a match should the rules engine continue running the remaining rules or stop. + * If not present, defaults to Continue. Possible values include: 'Continue', 'Stop' + */ + matchProcessingBehavior?: MatchProcessingBehavior; + /** + * Provisioning status. Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', + * 'Creating' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: AfdProvisioningState; + /** + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deploymentStatus?: DeploymentStatus; +} + +/** + * The domain JSON object required for domain creation or update. + */ +export interface RuleUpdateParameters { + /** + * The order in which the rules are applied for the endpoint. Possible values {0,1,2,3,………}. A + * rule with a lesser order will be applied before a rule with a greater order. Rule with order 0 + * is a special rule. It does not require any condition and actions listed in it will always be + * applied. + */ + order?: number; + /** + * A list of conditions that must be matched for the actions to be executed + */ + conditions?: DeliveryRuleConditionUnion[]; + /** + * A list of actions that are executed when all the conditions of a rule are satisfied. + */ + actions?: DeliveryRuleActionUnion[]; + /** + * If this rule is a match should the rules engine continue running the remaining rules or stop. + * If not present, defaults to Continue. Possible values include: 'Continue', 'Stop' + */ + matchProcessingBehavior?: MatchProcessingBehavior; +} + +/** + * The validation token. + */ +export interface ValidationToken { + /** + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly token?: string; +} + +/** + * Common error response for all Azure Resource Manager APIs to return error details for failed + * operations. (This also follows the OData error response format.). + * @summary Error response + */ +export interface AfdErrorResponse { + /** + * The error object. + */ + error?: ErrorResponse; +} + +/** + * An interface representing MetricsResponseSeriesItemGroupsItem. + */ +export interface MetricsResponseSeriesItemGroupsItem { + name?: string; + value?: string; +} + +/** + * An interface representing MetricsResponseSeriesItemDataItem. + */ +export interface MetricsResponseSeriesItemDataItem { + dateTime?: Date; + value?: number; +} + +/** + * An interface representing MetricsResponseSeriesItem. + */ +export interface MetricsResponseSeriesItem { + metric?: string; + /** + * Possible values include: 'count', 'bytes', 'bitsPerSecond' + */ + unit?: Unit; + groups?: MetricsResponseSeriesItemGroupsItem[]; + data?: MetricsResponseSeriesItemDataItem[]; +} + +/** + * Metrics Response + */ +export interface MetricsResponse { + dateTimeBegin?: Date; + dateTimeEnd?: Date; + /** + * Possible values include: 'PT5M', 'PT1H', 'P1D' + */ + granularity?: Granularity; + series?: MetricsResponseSeriesItem[]; +} + +/** + * An interface representing RankingsResponseTablesItemDataItemMetricsItem. + */ +export interface RankingsResponseTablesItemDataItemMetricsItem { + metric?: string; + value?: number; + percentage?: number; +} + +/** + * An interface representing RankingsResponseTablesItemDataItem. + */ +export interface RankingsResponseTablesItemDataItem { + name?: string; + metrics?: RankingsResponseTablesItemDataItemMetricsItem[]; +} + +/** + * An interface representing RankingsResponseTablesItem. + */ +export interface RankingsResponseTablesItem { + ranking?: string; + data?: RankingsResponseTablesItemDataItem[]; +} + +/** + * Rankings Response + */ +export interface RankingsResponse { + dateTimeBegin?: Date; + dateTimeEnd?: Date; + tables?: RankingsResponseTablesItem[]; +} + +/** + * An interface representing ContinentsResponseContinentsItem. + */ +export interface ContinentsResponseContinentsItem { + id?: string; +} + +/** + * An interface representing ContinentsResponseCountryOrRegionsItem. + */ +export interface ContinentsResponseCountryOrRegionsItem { + id?: string; + continentId?: string; +} + +/** + * Continents Response + */ +export interface ContinentsResponse { + continents?: ContinentsResponseContinentsItem[]; + countryOrRegions?: ContinentsResponseCountryOrRegionsItem[]; +} + +/** + * An interface representing ResourcesResponseEndpointsItemCustomDomainsItem. + */ +export interface ResourcesResponseEndpointsItemCustomDomainsItem { + id?: string; + name?: string; + endpointId?: string; + history?: boolean; +} + +/** + * An interface representing ResourcesResponseEndpointsItem. + */ +export interface ResourcesResponseEndpointsItem { + id?: string; + name?: string; + history?: boolean; + customDomains?: ResourcesResponseEndpointsItemCustomDomainsItem[]; +} + +/** + * An interface representing ResourcesResponseCustomDomainsItem. + */ +export interface ResourcesResponseCustomDomainsItem { + id?: string; + name?: string; + endpointId?: string; + history?: boolean; +} + +/** + * Resources Response + */ +export interface ResourcesResponse { + endpoints?: ResourcesResponseEndpointsItem[]; + customDomains?: ResourcesResponseCustomDomainsItem[]; +} + +/** + * An interface representing WafMetricsResponseSeriesItemGroupsItem. + */ +export interface WafMetricsResponseSeriesItemGroupsItem { + name?: string; + value?: string; +} + +/** + * An interface representing WafMetricsResponseSeriesItemDataItem. + */ +export interface WafMetricsResponseSeriesItemDataItem { + dateTime?: Date; + value?: number; +} + +/** + * An interface representing WafMetricsResponseSeriesItem. + */ +export interface WafMetricsResponseSeriesItem { + metric?: string; + /** + * Possible values include: 'count' + */ + unit?: Unit1; + groups?: WafMetricsResponseSeriesItemGroupsItem[]; + data?: WafMetricsResponseSeriesItemDataItem[]; +} + +/** + * Waf Metrics Response + */ +export interface WafMetricsResponse { + dateTimeBegin?: Date; + dateTimeEnd?: Date; + /** + * Possible values include: 'PT5M', 'PT1H', 'P1D' + */ + granularity?: Granularity1; + series?: WafMetricsResponseSeriesItem[]; +} + +/** + * An interface representing WafRankingsResponseDataItemMetricsItem. + */ +export interface WafRankingsResponseDataItemMetricsItem { + metric?: string; + value?: number; + percentage?: number; +} + +/** + * An interface representing WafRankingsResponseDataItem. + */ +export interface WafRankingsResponseDataItem { + groupValues?: string[]; + metrics?: WafRankingsResponseDataItemMetricsItem[]; +} + +/** + * Waf Rankings Response + */ +export interface WafRankingsResponse { + dateTimeBegin?: Date; + dateTimeEnd?: Date; + groups?: string[]; + data?: WafRankingsResponseDataItem[]; +} + +/** + * The usage names. + */ +export interface UsageName { + /** + * A string describing the resource name. + */ + value?: string; + /** + * A localized string describing the resource name. + */ + localizedValue?: string; +} + +/** + * Describes resource usage. + */ +export interface Usage { + /** + * Resource identifier. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The current value of the usage. + */ + currentValue: number; + /** + * The limit of usage. + */ + limit: number; + /** + * The name of the type of usage. + */ + name: UsageName; +} + +/** + * Defines contents of a web application firewall global configuration + */ +export interface PolicySettings { + /** + * describes if the policy is in enabled state or disabled state. Possible values include: + * 'Disabled', 'Enabled' + */ + enabledState?: PolicyEnabledState; + /** + * Describes if it is in detection mode or prevention mode at policy level. Possible values + * include: 'Prevention', 'Detection' + */ + mode?: PolicyMode; + /** + * If action type is redirect, this field represents the default redirect URL for the client. + */ + defaultRedirectUrl?: string; + /** + * If the action type is block, this field defines the default customer overridable http response + * status code. + */ + defaultCustomBlockResponseStatusCode?: number; + /** + * If the action type is block, customer can override the response body. The body must be + * specified in base64 encoding. + */ + defaultCustomBlockResponseBody?: string; +} + +/** + * Defines the common attributes for a custom rule that can be included in a waf policy + */ +export interface CustomRule { + /** + * Defines the name of the custom rule + */ + name: string; + /** + * Describes if the custom rule is in enabled or disabled state. Defaults to Enabled if not + * specified. Possible values include: 'Disabled', 'Enabled' + */ + enabledState?: CustomRuleEnabledState; + /** + * Defines in what order this rule be evaluated in the overall list of custom rules + */ + priority: number; + /** + * List of match conditions. + */ + matchConditions: MatchCondition[]; + /** + * Describes what action to be applied when rule matches. Possible values include: 'Allow', + * 'Block', 'Log', 'Redirect' + */ + action: ActionType; +} + +/** + * Defines a rate limiting rule that can be included in a waf policy + */ +export interface RateLimitRule extends CustomRule { + /** + * Defines rate limit threshold. + */ + rateLimitThreshold: number; + /** + * Defines rate limit duration. Default is 1 minute. + */ + rateLimitDurationInMinutes: number; +} + +/** + * Defines contents of rate limit rules + */ +export interface RateLimitRuleList { + /** + * List of rules + */ + rules?: RateLimitRule[]; +} + +/** + * Define match conditions + */ +export interface MatchCondition { + /** + * Match variable to compare against. Possible values include: 'RemoteAddr', 'SocketAddr', + * 'RequestMethod', 'RequestHeader', 'RequestUri', 'QueryString', 'RequestBody', 'Cookies', + * 'PostArgs' + */ + matchVariable: MatchVariable; + /** + * Selector can used to match a specific key for QueryString, Cookies, RequestHeader or PostArgs. + */ + selector?: string; + /** + * Describes operator to be matched. Possible values include: 'Any', 'IPMatch', 'GeoMatch', + * 'Equal', 'Contains', 'LessThan', 'GreaterThan', 'LessThanOrEqual', 'GreaterThanOrEqual', + * 'BeginsWith', 'EndsWith', 'RegEx' + */ + operator: Operator; + /** + * Describes if the result of this condition should be negated. + */ + negateCondition?: boolean; + /** + * List of possible match values. + */ + matchValue: string[]; + /** + * List of transforms. + */ + transforms?: TransformType[]; +} + +/** + * Defines contents of custom rules + */ +export interface CustomRuleList { + /** + * List of rules + */ + rules?: CustomRule[]; +} + +/** + * Defines a managed rule group override setting. + */ +export interface ManagedRuleOverride { + /** + * Identifier for the managed rule. + */ + ruleId: string; + /** + * Describes if the managed rule is in enabled or disabled state. Defaults to Disabled if not + * specified. Possible values include: 'Disabled', 'Enabled' + */ + enabledState?: ManagedRuleEnabledState; + /** + * Describes the override action to be applied when rule matches. Possible values include: + * 'Allow', 'Block', 'Log', 'Redirect' + */ + action?: ActionType; +} + +/** + * Defines a managed rule group override setting. + */ +export interface ManagedRuleGroupOverride { + /** + * Describes the managed rule group within the rule set to override + */ + ruleGroupName: string; + /** + * List of rules that will be disabled. If none specified, all rules in the group will be + * disabled. + */ + rules?: ManagedRuleOverride[]; +} + +/** + * Defines a managed rule set. + */ +export interface ManagedRuleSet { + /** + * Defines the rule set type to use. + */ + ruleSetType: string; + /** + * Defines the version of the rule set to use. + */ + ruleSetVersion: string; + /** + * Verizon only : If the rule set supports anomaly detection mode, this describes the threshold + * for blocking requests. + */ + anomalyScore?: number; + /** + * Defines the rule overrides to apply to the rule set. + */ + ruleGroupOverrides?: ManagedRuleGroupOverride[]; +} + +/** + * Defines the list of managed rule sets for the policy. + */ +export interface ManagedRuleSetList { + /** + * List of rule sets. + */ + managedRuleSets?: ManagedRuleSet[]; +} + +/** + * Defines the ARM Resource ID for the linked endpoints + */ +export interface CdnEndpoint { + /** + * ARM Resource ID string. + */ + id?: string; +} + +/** + * Defines web application firewall policy for Azure CDN. + */ +export interface CdnWebApplicationFirewallPolicy extends TrackedResource { + /** + * Describes policySettings for policy + */ + policySettings?: PolicySettings; + /** + * Describes rate limit rules inside the policy. + */ + rateLimitRules?: RateLimitRuleList; + /** + * Describes custom rules inside the policy. + */ + customRules?: CustomRuleList; + /** + * Describes managed rules inside the policy. + */ + managedRules?: ManagedRuleSetList; + /** + * Describes Azure CDN endpoints associated with this Web Application Firewall policy. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly endpointLinks?: CdnEndpoint[]; + /** + * Provisioning state of the WebApplicationFirewallPolicy. Possible values include: 'Creating', + * 'Succeeded', 'Failed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: ProvisioningState; + /** + * Resource status of the policy. Possible values include: 'Creating', 'Enabling', 'Enabled', + * 'Disabling', 'Disabled', 'Deleting' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly resourceState?: PolicyResourceState; + /** + * Gets a unique read-only string that changes whenever the resource is updated. + */ + etag?: string; + /** + * The pricing tier (defines a CDN provider, feature list and rate) of the + * CdnWebApplicationFirewallPolicy. + */ + sku: Sku; +} + +/** + * Properties required to update a CdnWebApplicationFirewallPolicy. + */ +export interface CdnWebApplicationFirewallPolicyPatchParameters extends BaseResource { + /** + * CdnWebApplicationFirewallPolicy tags + */ + tags?: { [propertyName: string]: string }; +} + +/** + * Describes a managed rule definition. + */ +export interface ManagedRuleDefinition { + /** + * Identifier for the managed rule. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ruleId?: string; + /** + * Describes the functionality of the managed rule. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly description?: string; +} + +/** + * Describes a managed rule group. + */ +export interface ManagedRuleGroupDefinition { + /** + * Name of the managed rule group. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ruleGroupName?: string; + /** + * Description of the managed rule group. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly description?: string; + /** + * List of rules within the managed rule group. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly rules?: ManagedRuleDefinition[]; +} + +/** + * Describes a managed rule set definition. + */ +export interface ManagedRuleSetDefinition extends Resource { + /** + * Provisioning state of the managed rule set. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly provisioningState?: string; + /** + * Type of the managed rule set. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ruleSetType?: string; + /** + * Version of the managed rule set type. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ruleSetVersion?: string; + /** + * Rule groups of the managed rule set. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ruleGroups?: ManagedRuleGroupDefinition[]; + /** + * The pricing tier (defines a CDN provider, feature list and rate) of the + * CdnWebApplicationFirewallPolicy. + */ + sku?: Sku; +} + +/** + * Optional Parameters. + */ +export interface ProfilesUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * Profile tags + */ + tags?: { [propertyName: string]: string }; +} + +/** + * Optional Parameters. + */ +export interface ProfilesBeginUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * Profile tags + */ + tags?: { [propertyName: string]: string }; +} + +/** + * Optional Parameters. + */ +export interface CustomDomainsEnableCustomHttpsOptionalParams extends msRest.RequestOptionsBase { + /** + * The configuration specifying how to enable HTTPS for the custom domain - using CDN managed + * certificate or user's own certificate. If not specified, enabling ssl uses CDN managed + * certificate by default. + */ + customDomainHttpsParameters?: CustomDomainHttpsParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface CustomDomainsBeginEnableCustomHttpsOptionalParams extends msRest.RequestOptionsBase { + /** + * The configuration specifying how to enable HTTPS for the custom domain - using CDN managed + * certificate or user's own certificate. If not specified, enabling ssl uses CDN managed + * certificate by default. + */ + customDomainHttpsParameters?: CustomDomainHttpsParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface AFDCustomDomainsUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * The configuration specifying how to enable HTTPS for the domain - using AzureFrontDoor managed + * certificate or user's own certificate. If not specified, enabling ssl uses AzureFrontDoor + * managed certificate by default. + */ + tlsSettings?: AFDDomainHttpsParameters; + /** + * Resource reference to the Azure DNS zone + */ + azureDnsZone?: ResourceReference; +} + +/** + * Optional Parameters. + */ +export interface AFDCustomDomainsBeginUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * The configuration specifying how to enable HTTPS for the domain - using AzureFrontDoor managed + * certificate or user's own certificate. If not specified, enabling ssl uses AzureFrontDoor + * managed certificate by default. + */ + tlsSettings?: AFDDomainHttpsParameters; + /** + * Resource reference to the Azure DNS zone + */ + azureDnsZone?: ResourceReference; +} + +/** + * Optional Parameters. + */ +export interface AFDEndpointsPurgeContentOptionalParams extends msRest.RequestOptionsBase { + /** + * List of domains. + */ + domains?: string[]; +} + +/** + * Optional Parameters. + */ +export interface AFDEndpointsBeginPurgeContentOptionalParams extends msRest.RequestOptionsBase { + /** + * List of domains. + */ + domains?: string[]; +} + +/** + * Optional Parameters. + */ +export interface SecurityPoliciesCreateOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains security policy parameters + */ + parameters?: SecurityPolicyParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface SecurityPoliciesPatchOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains security policy parameters + */ + parameters?: SecurityPolicyParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface SecurityPoliciesBeginCreateOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains security policy parameters + */ + parameters?: SecurityPolicyParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface SecurityPoliciesBeginPatchOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains security policy parameters + */ + parameters?: SecurityPolicyParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface SecretsCreateOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains secret parameters + */ + parameters?: SecretParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface SecretsUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains secret parameters + */ + parameters?: SecretParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface SecretsBeginCreateOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains secret parameters + */ + parameters?: SecretParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface SecretsBeginUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * object which contains secret parameters + */ + parameters?: SecretParametersUnion; +} + +/** + * Optional Parameters. + */ +export interface LogAnalyticsGetLogAnalyticsMetricsOptionalParams extends msRest.RequestOptionsBase { + groupBy?: LogMetricsGroupBy[]; + continents?: string[]; + countryOrRegions?: string[]; +} + +/** + * Optional Parameters. + */ +export interface LogAnalyticsGetLogAnalyticsRankingsOptionalParams extends msRest.RequestOptionsBase { + customDomains?: string[]; +} + +/** + * Optional Parameters. + */ +export interface LogAnalyticsGetWafLogAnalyticsMetricsOptionalParams extends msRest.RequestOptionsBase { + actions?: WafAction[]; + groupBy?: WafRankingGroupBy[]; + ruleTypes?: WafRuleType[]; +} + +/** + * Optional Parameters. + */ +export interface LogAnalyticsGetWafLogAnalyticsRankingsOptionalParams extends msRest.RequestOptionsBase { + actions?: WafAction[]; + ruleTypes?: WafRuleType[]; +} + +/** + * Optional Parameters. + */ +export interface PoliciesUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * CdnWebApplicationFirewallPolicy tags + */ + tags?: { [propertyName: string]: string }; +} + +/** + * Optional Parameters. + */ +export interface PoliciesBeginUpdateOptionalParams extends msRest.RequestOptionsBase { + /** + * CdnWebApplicationFirewallPolicy tags + */ + tags?: { [propertyName: string]: string }; +} + +/** + * An interface representing CdnManagementClientOptions. + */ +export interface CdnManagementClientOptions extends AzureServiceClientOptions { + baseUri?: string; +} + +/** + * @interface + * Result of the request to list profiles. It contains a list of profile objects and a URL link to + * get the next set of results. + * @extends Array + */ +export interface ProfileListResult extends Array { + /** + * URL to get the next set of profile objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Output of check resource usage API. + * @extends Array + */ +export interface ResourceUsageListResult extends Array { + /** + * URL to get the next set of custom domain objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list endpoints. It contains a list of endpoint objects and a URL link + * to get the next set of results. + * @extends Array + */ +export interface EndpointListResult extends Array { + /** + * URL to get the next set of endpoint objects if there is any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list origins. It contains a list of origin objects and a URL link to + * get the next set of results. + * @extends Array + */ +export interface OriginListResult extends Array { + /** + * URL to get the next set of origin objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list origin groups. It contains a list of origin groups objects and a + * URL link to get the next set of results. + * @extends Array + */ +export interface OriginGroupListResult extends Array { + /** + * URL to get the next set of origin objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list custom domains. It contains a list of custom domain objects and a + * URL link to get the next set of results. + * @extends Array + */ +export interface CustomDomainListResult extends Array { + /** + * URL to get the next set of custom domain objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list CDN operations. It contains a list of operations and a URL link to + * get the next set of results. + * @extends Array + */ +export interface OperationsListResult extends Array { + /** + * URL to get the next set of operation list results if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list CDN edgenodes. It contains a list of ip address group and a URL + * link to get the next set of results. + * @extends Array + */ +export interface EdgenodeResult extends Array { + /** + * URL to get the next set of edgenode list results if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * The list usages operation response. + * @extends Array + */ +export interface UsagesListResult extends Array { + /** + * URL to get the next set of results. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list domains. It contains a list of domain objects and a URL link to + * get the next set of results. + * @extends Array + */ +export interface AFDDomainListResult extends Array { + /** + * URL to get the next set of domain objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list endpoints. It contains a list of endpoint objects and a URL link + * to get the next set of results. + * @extends Array + */ +export interface AFDEndpointListResult extends Array { + /** + * URL to get the next set of endpoint objects if there is any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list origin groups. It contains a list of origin groups objects and a + * URL link to get the next set of results. + * @extends Array + */ +export interface AFDOriginGroupListResult extends Array { + /** + * URL to get the next set of origin objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list origins. It contains a list of origin objects and a URL link to + * get the next set of results. + * @extends Array + */ +export interface AFDOriginListResult extends Array { + /** + * URL to get the next set of origin objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list routes. It contains a list of route objects and a URL link to get + * the next set of results. + * @extends Array + */ +export interface RouteListResult extends Array { + /** + * URL to get the next set of route objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list rule sets. It contains a list of rule set objects and a URL link + * to get the next set of results. + * @extends Array + */ +export interface RuleSetListResult extends Array { + /** + * URL to get the next set of rule set objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list rules. It contains a list of rule objects and a URL link to get + * the next set of results. + * @extends Array + */ +export interface RuleListResult extends Array { + /** + * URL to get the next set of rule objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list security policies. It contains a list of security policy objects + * and a URL link to get the next set of results. + * @extends Array + */ +export interface SecurityPolicyListResult extends Array { + /** + * URL to get the next set of security policy objects if there is any. + */ + nextLink?: string; +} + +/** + * @interface + * Result of the request to list secrets. It contains a list of Secret objects and a URL link to + * get the next set of results. + * @extends Array + */ +export interface SecretListResult extends Array { + /** + * URL to get the next set of Secret objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * Defines a list of WebApplicationFirewallPolicies for Azure CDN. It contains a list of + * WebApplicationFirewallPolicy objects and a URL link to get the next set of results. + * @extends Array + */ +export interface CdnWebApplicationFirewallPolicyList extends Array { + /** + * URL to get the next set of WebApplicationFirewallPolicy objects if there are any. + */ + nextLink?: string; +} + +/** + * @interface + * List of managed rule set definitions available for use in a policy. + * @extends Array + */ +export interface ManagedRuleSetDefinitionList extends Array { + /** + * URL to retrieve next set of managed rule set definitions. + */ + nextLink?: string; +} + +/** + * Defines values for SkuName. + * Possible values include: 'Standard_Verizon', 'Premium_Verizon', 'Custom_Verizon', + * 'Standard_Akamai', 'Standard_ChinaCdn', 'Standard_Microsoft', 'Premium_ChinaCdn', + * 'Standard_AzureFrontDoor', 'Premium_AzureFrontDoor', 'Standard_955BandWidth_ChinaCdn', + * 'Standard_AvgBandWidth_ChinaCdn', 'StandardPlus_ChinaCdn', 'StandardPlus_955BandWidth_ChinaCdn', + * 'StandardPlus_AvgBandWidth_ChinaCdn' + * @readonly + * @enum {string} + */ +export type SkuName = 'Standard_Verizon' | 'Premium_Verizon' | 'Custom_Verizon' | 'Standard_Akamai' | 'Standard_ChinaCdn' | 'Standard_Microsoft' | 'Premium_ChinaCdn' | 'Standard_AzureFrontDoor' | 'Premium_AzureFrontDoor' | 'Standard_955BandWidth_ChinaCdn' | 'Standard_AvgBandWidth_ChinaCdn' | 'StandardPlus_ChinaCdn' | 'StandardPlus_955BandWidth_ChinaCdn' | 'StandardPlus_AvgBandWidth_ChinaCdn'; + +/** + * Defines values for ProfileResourceState. + * Possible values include: 'Creating', 'Active', 'Deleting', 'Disabled' + * @readonly + * @enum {string} + */ +export type ProfileResourceState = 'Creating' | 'Active' | 'Deleting' | 'Disabled'; + +/** + * Defines values for OptimizationType. + * Possible values include: 'GeneralWebDelivery', 'GeneralMediaStreaming', + * 'VideoOnDemandMediaStreaming', 'LargeFileDownload', 'DynamicSiteAcceleration' + * @readonly + * @enum {string} + */ +export type OptimizationType = 'GeneralWebDelivery' | 'GeneralMediaStreaming' | 'VideoOnDemandMediaStreaming' | 'LargeFileDownload' | 'DynamicSiteAcceleration'; + +/** + * Defines values for HealthProbeRequestType. + * Possible values include: 'NotSet', 'GET', 'HEAD' + * @readonly + * @enum {string} + */ +export type HealthProbeRequestType = 'NotSet' | 'GET' | 'HEAD'; + +/** + * Defines values for ProbeProtocol. + * Possible values include: 'NotSet', 'Http', 'Https' + * @readonly + * @enum {string} + */ +export type ProbeProtocol = 'NotSet' | 'Http' | 'Https'; + +/** + * Defines values for ResponseBasedDetectedErrorTypes. + * Possible values include: 'None', 'TcpErrorsOnly', 'TcpAndHttpErrors' + * @readonly + * @enum {string} + */ +export type ResponseBasedDetectedErrorTypes = 'None' | 'TcpErrorsOnly' | 'TcpAndHttpErrors'; + +/** + * Defines values for EndpointResourceState. + * Possible values include: 'Creating', 'Deleting', 'Running', 'Starting', 'Stopped', 'Stopping' + * @readonly + * @enum {string} + */ +export type EndpointResourceState = 'Creating' | 'Deleting' | 'Running' | 'Starting' | 'Stopped' | 'Stopping'; + +/** + * Defines values for QueryStringCachingBehavior. + * Possible values include: 'IgnoreQueryString', 'BypassCaching', 'UseQueryString', 'NotSet' + * @readonly + * @enum {string} + */ +export type QueryStringCachingBehavior = 'IgnoreQueryString' | 'BypassCaching' | 'UseQueryString' | 'NotSet'; + +/** + * Defines values for GeoFilterActions. + * Possible values include: 'Block', 'Allow' + * @readonly + * @enum {string} + */ +export type GeoFilterActions = 'Block' | 'Allow'; + +/** + * Defines values for RemoteAddressOperator. + * Possible values include: 'Any', 'IPMatch', 'GeoMatch' + * @readonly + * @enum {string} + */ +export type RemoteAddressOperator = 'Any' | 'IPMatch' | 'GeoMatch'; + +/** + * Defines values for Transform. + * Possible values include: 'Lowercase', 'Uppercase' + * @readonly + * @enum {string} + */ +export type Transform = 'Lowercase' | 'Uppercase'; + +/** + * Defines values for QueryStringOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type QueryStringOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for PostArgsOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type PostArgsOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for RequestUriOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type RequestUriOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for RequestHeaderOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type RequestHeaderOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for RequestBodyOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type RequestBodyOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for UrlPathOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'Wildcard', 'RegEx' + * @readonly + * @enum {string} + */ +export type UrlPathOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'Wildcard' | 'RegEx'; + +/** + * Defines values for UrlFileExtensionOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type UrlFileExtensionOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for UrlFileNameOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type UrlFileNameOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for CookiesOperator. + * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', + * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'RegEx' + * @readonly + * @enum {string} + */ +export type CookiesOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'RegEx'; + +/** + * Defines values for RedirectType. + * Possible values include: 'Moved', 'Found', 'TemporaryRedirect', 'PermanentRedirect' + * @readonly + * @enum {string} + */ +export type RedirectType = 'Moved' | 'Found' | 'TemporaryRedirect' | 'PermanentRedirect'; + +/** + * Defines values for DestinationProtocol. + * Possible values include: 'MatchRequest', 'Http', 'Https' + * @readonly + * @enum {string} + */ +export type DestinationProtocol = 'MatchRequest' | 'Http' | 'Https'; + +/** + * Defines values for Algorithm. + * Possible values include: 'SHA256' + * @readonly + * @enum {string} + */ +export type Algorithm = 'SHA256'; + +/** + * Defines values for ParamIndicator. + * Possible values include: 'Expires', 'KeyId', 'Signature' + * @readonly + * @enum {string} + */ +export type ParamIndicator = 'Expires' | 'KeyId' | 'Signature'; + +/** + * Defines values for HeaderAction. + * Possible values include: 'Append', 'Overwrite', 'Delete' + * @readonly + * @enum {string} + */ +export type HeaderAction = 'Append' | 'Overwrite' | 'Delete'; + +/** + * Defines values for CacheBehavior. + * Possible values include: 'BypassCache', 'Override', 'SetIfMissing' + * @readonly + * @enum {string} + */ +export type CacheBehavior = 'BypassCache' | 'Override' | 'SetIfMissing'; + +/** + * Defines values for QueryStringBehavior. + * Possible values include: 'Include', 'IncludeAll', 'Exclude', 'ExcludeAll' + * @readonly + * @enum {string} + */ +export type QueryStringBehavior = 'Include' | 'IncludeAll' | 'Exclude' | 'ExcludeAll'; + +/** + * Defines values for OriginResourceState. + * Possible values include: 'Creating', 'Active', 'Deleting' + * @readonly + * @enum {string} + */ +export type OriginResourceState = 'Creating' | 'Active' | 'Deleting'; + +/** + * Defines values for PrivateEndpointStatus. + * Possible values include: 'Pending', 'Approved', 'Rejected', 'Disconnected', 'Timeout' + * @readonly + * @enum {string} + */ +export type PrivateEndpointStatus = 'Pending' | 'Approved' | 'Rejected' | 'Disconnected' | 'Timeout'; + +/** + * Defines values for OriginGroupResourceState. + * Possible values include: 'Creating', 'Active', 'Deleting' + * @readonly + * @enum {string} + */ +export type OriginGroupResourceState = 'Creating' | 'Active' | 'Deleting'; + +/** + * Defines values for CustomDomainResourceState. + * Possible values include: 'Creating', 'Active', 'Deleting' + * @readonly + * @enum {string} + */ +export type CustomDomainResourceState = 'Creating' | 'Active' | 'Deleting'; + +/** + * Defines values for CustomHttpsProvisioningState. + * Possible values include: 'Enabling', 'Enabled', 'Disabling', 'Disabled', 'Failed' + * @readonly + * @enum {string} + */ +export type CustomHttpsProvisioningState = 'Enabling' | 'Enabled' | 'Disabling' | 'Disabled' | 'Failed'; + +/** + * Defines values for CustomHttpsProvisioningSubstate. + * Possible values include: 'SubmittingDomainControlValidationRequest', + * 'PendingDomainControlValidationREquestApproval', 'DomainControlValidationRequestApproved', + * 'DomainControlValidationRequestRejected', 'DomainControlValidationRequestTimedOut', + * 'IssuingCertificate', 'DeployingCertificate', 'CertificateDeployed', 'DeletingCertificate', + * 'CertificateDeleted' + * @readonly + * @enum {string} + */ +export type CustomHttpsProvisioningSubstate = 'SubmittingDomainControlValidationRequest' | 'PendingDomainControlValidationREquestApproval' | 'DomainControlValidationRequestApproved' | 'DomainControlValidationRequestRejected' | 'DomainControlValidationRequestTimedOut' | 'IssuingCertificate' | 'DeployingCertificate' | 'CertificateDeployed' | 'DeletingCertificate' | 'CertificateDeleted'; + +/** + * Defines values for ProtocolType. + * Possible values include: 'ServerNameIndication', 'IPBased' + * @readonly + * @enum {string} + */ +export type ProtocolType = 'ServerNameIndication' | 'IPBased'; + +/** + * Defines values for MinimumTlsVersion. + * Possible values include: 'None', 'TLS10', 'TLS12' + * @readonly + * @enum {string} + */ +export type MinimumTlsVersion = 'None' | 'TLS10' | 'TLS12'; + +/** + * Defines values for CertificateType. + * Possible values include: 'Shared', 'Dedicated' + * @readonly + * @enum {string} + */ +export type CertificateType = 'Shared' | 'Dedicated'; + +/** + * Defines values for ResourceType. + * Possible values include: 'Microsoft.Cdn/Profiles/Endpoints' + * @readonly + * @enum {string} + */ +export type ResourceType = 'Microsoft.Cdn/Profiles/Endpoints'; + +/** + * Defines values for IdentityType. + * Possible values include: 'user', 'application', 'managedIdentity', 'key' + * @readonly + * @enum {string} + */ +export type IdentityType = 'user' | 'application' | 'managedIdentity' | 'key'; + +/** + * Defines values for ValidateSecretType. + * Possible values include: 'UrlSigningKey', 'ManagedCertificate', 'CustomerCertificate' + * @readonly + * @enum {string} + */ +export type ValidateSecretType = 'UrlSigningKey' | 'ManagedCertificate' | 'CustomerCertificate'; + +/** + * Defines values for Status. + * Possible values include: 'Valid', 'Invalid', 'AccessDenied', 'CertificateExpired' + * @readonly + * @enum {string} + */ +export type Status = 'Valid' | 'Invalid' | 'AccessDenied' | 'CertificateExpired'; + +/** + * Defines values for AfdCertificateType. + * Possible values include: 'CustomerCertificate', 'ManagedCertificate' + * @readonly + * @enum {string} + */ +export type AfdCertificateType = 'CustomerCertificate' | 'ManagedCertificate'; + +/** + * Defines values for AfdMinimumTlsVersion. + * Possible values include: 'TLS10', 'TLS12' + * @readonly + * @enum {string} + */ +export type AfdMinimumTlsVersion = 'TLS10' | 'TLS12'; + +/** + * Defines values for AfdProvisioningState. + * Possible values include: 'Succeeded', 'Failed', 'Updating', 'Deleting', 'Creating' + * @readonly + * @enum {string} + */ +export type AfdProvisioningState = 'Succeeded' | 'Failed' | 'Updating' | 'Deleting' | 'Creating'; + +/** + * Defines values for DeploymentStatus. + * Possible values include: 'NotStarted', 'InProgress', 'Succeeded', 'Failed' + * @readonly + * @enum {string} + */ +export type DeploymentStatus = 'NotStarted' | 'InProgress' | 'Succeeded' | 'Failed'; + +/** + * Defines values for DomainValidationState. + * Possible values include: 'Unknown', 'Submitting', 'Pending', 'TimedOut', 'PendingRevalidation', + * 'Approved' + * @readonly + * @enum {string} + */ +export type DomainValidationState = 'Unknown' | 'Submitting' | 'Pending' | 'TimedOut' | 'PendingRevalidation' | 'Approved'; + +/** + * Defines values for EnabledState. + * Possible values include: 'Enabled', 'Disabled' + * @readonly + * @enum {string} + */ +export type EnabledState = 'Enabled' | 'Disabled'; + +/** + * Defines values for AFDEndpointProtocols. + * Possible values include: 'Http', 'Https' + * @readonly + * @enum {string} + */ +export type AFDEndpointProtocols = 'Http' | 'Https'; + +/** + * Defines values for SharedPrivateLinkResourceStatus. + * Possible values include: 'Pending', 'Approved', 'Rejected', 'Disconnected', 'Timeout' + * @readonly + * @enum {string} + */ +export type SharedPrivateLinkResourceStatus = 'Pending' | 'Approved' | 'Rejected' | 'Disconnected' | 'Timeout'; + +/** + * Defines values for AfdQueryStringCachingBehavior. + * Possible values include: 'IgnoreQueryString', 'UseQueryString', 'NotSet' + * @readonly + * @enum {string} + */ +export type AfdQueryStringCachingBehavior = 'IgnoreQueryString' | 'UseQueryString' | 'NotSet'; + +/** + * Defines values for ForwardingProtocol. + * Possible values include: 'HttpOnly', 'HttpsOnly', 'MatchRequest' + * @readonly + * @enum {string} + */ +export type ForwardingProtocol = 'HttpOnly' | 'HttpsOnly' | 'MatchRequest'; + +/** + * Defines values for LinkToDefaultDomain. + * Possible values include: 'Enabled', 'Disabled' + * @readonly + * @enum {string} + */ +export type LinkToDefaultDomain = 'Enabled' | 'Disabled'; + +/** + * Defines values for HttpsRedirect. + * Possible values include: 'Enabled', 'Disabled' + * @readonly + * @enum {string} + */ +export type HttpsRedirect = 'Enabled' | 'Disabled'; + +/** + * Defines values for MatchProcessingBehavior. + * Possible values include: 'Continue', 'Stop' + * @readonly + * @enum {string} + */ +export type MatchProcessingBehavior = 'Continue' | 'Stop'; + +/** + * Defines values for PolicyEnabledState. + * Possible values include: 'Disabled', 'Enabled' + * @readonly + * @enum {string} + */ +export type PolicyEnabledState = 'Disabled' | 'Enabled'; + +/** + * Defines values for PolicyMode. + * Possible values include: 'Prevention', 'Detection' + * @readonly + * @enum {string} + */ +export type PolicyMode = 'Prevention' | 'Detection'; + +/** + * Defines values for CustomRuleEnabledState. + * Possible values include: 'Disabled', 'Enabled' + * @readonly + * @enum {string} + */ +export type CustomRuleEnabledState = 'Disabled' | 'Enabled'; + +/** + * Defines values for MatchVariable. + * Possible values include: 'RemoteAddr', 'SocketAddr', 'RequestMethod', 'RequestHeader', + * 'RequestUri', 'QueryString', 'RequestBody', 'Cookies', 'PostArgs' + * @readonly + * @enum {string} + */ +export type MatchVariable = 'RemoteAddr' | 'SocketAddr' | 'RequestMethod' | 'RequestHeader' | 'RequestUri' | 'QueryString' | 'RequestBody' | 'Cookies' | 'PostArgs'; + +/** + * Defines values for Operator. + * Possible values include: 'Any', 'IPMatch', 'GeoMatch', 'Equal', 'Contains', 'LessThan', + * 'GreaterThan', 'LessThanOrEqual', 'GreaterThanOrEqual', 'BeginsWith', 'EndsWith', 'RegEx' + * @readonly + * @enum {string} + */ +export type Operator = 'Any' | 'IPMatch' | 'GeoMatch' | 'Equal' | 'Contains' | 'LessThan' | 'GreaterThan' | 'LessThanOrEqual' | 'GreaterThanOrEqual' | 'BeginsWith' | 'EndsWith' | 'RegEx'; + +/** + * Defines values for TransformType. + * Possible values include: 'Lowercase', 'Uppercase', 'Trim', 'UrlDecode', 'UrlEncode', + * 'RemoveNulls' + * @readonly + * @enum {string} + */ +export type TransformType = 'Lowercase' | 'Uppercase' | 'Trim' | 'UrlDecode' | 'UrlEncode' | 'RemoveNulls'; + +/** + * Defines values for ActionType. + * Possible values include: 'Allow', 'Block', 'Log', 'Redirect' + * @readonly + * @enum {string} + */ +export type ActionType = 'Allow' | 'Block' | 'Log' | 'Redirect'; + +/** + * Defines values for ManagedRuleEnabledState. + * Possible values include: 'Disabled', 'Enabled' + * @readonly + * @enum {string} + */ +export type ManagedRuleEnabledState = 'Disabled' | 'Enabled'; + +/** + * Defines values for ProvisioningState. + * Possible values include: 'Creating', 'Succeeded', 'Failed' + * @readonly + * @enum {string} + */ +export type ProvisioningState = 'Creating' | 'Succeeded' | 'Failed'; + +/** + * Defines values for PolicyResourceState. + * Possible values include: 'Creating', 'Enabling', 'Enabled', 'Disabling', 'Disabled', 'Deleting' + * @readonly + * @enum {string} + */ +export type PolicyResourceState = 'Creating' | 'Enabling' | 'Enabled' | 'Disabling' | 'Disabled' | 'Deleting'; + +/** + * Defines values for LogMetric. + * Possible values include: 'clientRequestCount', 'clientRequestTraffic', 'clientRequestBandwidth', + * 'originRequestTraffic', 'originRequestBandwidth', 'totalLatency' + * @readonly + * @enum {string} + */ +export type LogMetric = 'clientRequestCount' | 'clientRequestTraffic' | 'clientRequestBandwidth' | 'originRequestTraffic' | 'originRequestBandwidth' | 'totalLatency'; + +/** + * Defines values for LogMetricsGranularity. + * Possible values include: 'PT5M', 'PT1H', 'P1D' + * @readonly + * @enum {string} + */ +export type LogMetricsGranularity = 'PT5M' | 'PT1H' | 'P1D'; + +/** + * Defines values for LogMetricsGroupBy. + * Possible values include: 'httpStatusCode', 'protocol', 'cacheStatus', 'country', 'customDomain' + * @readonly + * @enum {string} + */ +export type LogMetricsGroupBy = 'httpStatusCode' | 'protocol' | 'cacheStatus' | 'country' | 'customDomain'; + +/** + * Defines values for LogRanking. + * Possible values include: 'url', 'referrer', 'browser', 'userAgent', 'countryOrRegion' + * @readonly + * @enum {string} + */ +export type LogRanking = 'url' | 'referrer' | 'browser' | 'userAgent' | 'countryOrRegion'; + +/** + * Defines values for LogRankingMetric. + * Possible values include: 'clientRequestCount', 'clientRequestTraffic', 'hitCount', 'missCount', + * 'userErrorCount', 'errorCount' + * @readonly + * @enum {string} + */ +export type LogRankingMetric = 'clientRequestCount' | 'clientRequestTraffic' | 'hitCount' | 'missCount' | 'userErrorCount' | 'errorCount'; + +/** + * Defines values for WafMetric. + * Possible values include: 'clientRequestCount' + * @readonly + * @enum {string} + */ +export type WafMetric = 'clientRequestCount'; + +/** + * Defines values for WafGranularity. + * Possible values include: 'PT5M', 'PT1H', 'P1D' + * @readonly + * @enum {string} + */ +export type WafGranularity = 'PT5M' | 'PT1H' | 'P1D'; + +/** + * Defines values for WafAction. + * Possible values include: 'allow', 'block', 'log', 'redirect' + * @readonly + * @enum {string} + */ +export type WafAction = 'allow' | 'block' | 'log' | 'redirect'; + +/** + * Defines values for WafRankingGroupBy. + * Possible values include: 'httpStatusCode', 'customDomain' + * @readonly + * @enum {string} + */ +export type WafRankingGroupBy = 'httpStatusCode' | 'customDomain'; + +/** + * Defines values for WafRuleType. + * Possible values include: 'managed', 'custom', 'bot' + * @readonly + * @enum {string} + */ +export type WafRuleType = 'managed' | 'custom' | 'bot'; + +/** + * Defines values for WafRankingType. + * Possible values include: 'action', 'ruleGroup', 'ruleId', 'userAgent', 'clientIp', 'url', + * 'country', 'ruleType' + * @readonly + * @enum {string} + */ +export type WafRankingType = 'action' | 'ruleGroup' | 'ruleId' | 'userAgent' | 'clientIp' | 'url' | 'country' | 'ruleType'; + +/** + * Defines values for Unit. + * Possible values include: 'count', 'bytes', 'bitsPerSecond' + * @readonly + * @enum {string} + */ +export type Unit = 'count' | 'bytes' | 'bitsPerSecond'; + +/** + * Defines values for Granularity. + * Possible values include: 'PT5M', 'PT1H', 'P1D' + * @readonly + * @enum {string} + */ +export type Granularity = 'PT5M' | 'PT1H' | 'P1D'; + +/** + * Defines values for Unit1. + * Possible values include: 'count' + * @readonly + * @enum {string} + */ +export type Unit1 = 'count'; + +/** + * Defines values for Granularity1. + * Possible values include: 'PT5M', 'PT1H', 'P1D' * @readonly * @enum {string} */ -export type ProfileResourceState = 'Creating' | 'Active' | 'Deleting' | 'Disabled'; +export type Granularity1 = 'PT5M' | 'PT1H' | 'P1D'; + +/** + * Contains response data for the list operation. + */ +export type ProfilesListResponse = ProfileListResult & { + /** + * 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: ProfileListResult; + }; +}; + +/** + * Contains response data for the listByResourceGroup operation. + */ +export type ProfilesListByResourceGroupResponse = ProfileListResult & { + /** + * 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: ProfileListResult; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type ProfilesGetResponse = Profile & { + /** + * 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: Profile; + }; +}; + +/** + * Contains response data for the create operation. + */ +export type ProfilesCreateResponse = Profile & { + /** + * 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: Profile; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type ProfilesUpdateResponse = Profile & { + /** + * 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: Profile; + }; +}; + +/** + * Contains response data for the generateSsoUri operation. + */ +export type ProfilesGenerateSsoUriResponse = SsoUri & { + /** + * 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: SsoUri; + }; +}; + +/** + * Contains response data for the listSupportedOptimizationTypes operation. + */ +export type ProfilesListSupportedOptimizationTypesResponse = SupportedOptimizationTypesListResult & { + /** + * 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: SupportedOptimizationTypesListResult; + }; +}; + +/** + * Contains response data for the listResourceUsage operation. + */ +export type ProfilesListResourceUsageResponse = ResourceUsageListResult & { + /** + * 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: ResourceUsageListResult; + }; +}; + +/** + * Contains response data for the beginCreate operation. + */ +export type ProfilesBeginCreateResponse = Profile & { + /** + * 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: Profile; + }; +}; + +/** + * Contains response data for the beginUpdate operation. + */ +export type ProfilesBeginUpdateResponse = Profile & { + /** + * 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: Profile; + }; +}; + +/** + * Contains response data for the listNext operation. + */ +export type ProfilesListNextResponse = ProfileListResult & { + /** + * 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: ProfileListResult; + }; +}; + +/** + * Contains response data for the listByResourceGroupNext operation. + */ +export type ProfilesListByResourceGroupNextResponse = ProfileListResult & { + /** + * 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: ProfileListResult; + }; +}; + +/** + * Contains response data for the listResourceUsageNext operation. + */ +export type ProfilesListResourceUsageNextResponse = ResourceUsageListResult & { + /** + * 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: ResourceUsageListResult; + }; +}; + +/** + * Contains response data for the listByProfile operation. + */ +export type EndpointsListByProfileResponse = EndpointListResult & { + /** + * 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: EndpointListResult; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type EndpointsGetResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the create operation. + */ +export type EndpointsCreateResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type EndpointsUpdateResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the start operation. + */ +export type EndpointsStartResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the stop operation. + */ +export type EndpointsStopResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the validateCustomDomain operation. + */ +export type EndpointsValidateCustomDomainResponse = ValidateCustomDomainOutput & { + /** + * 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: ValidateCustomDomainOutput; + }; +}; + +/** + * Contains response data for the listResourceUsage operation. + */ +export type EndpointsListResourceUsageResponse = ResourceUsageListResult & { + /** + * 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: ResourceUsageListResult; + }; +}; + +/** + * Contains response data for the beginCreate operation. + */ +export type EndpointsBeginCreateResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the beginUpdate operation. + */ +export type EndpointsBeginUpdateResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the beginStart operation. + */ +export type EndpointsBeginStartResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the beginStop operation. + */ +export type EndpointsBeginStopResponse = Endpoint & { + /** + * 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: Endpoint; + }; +}; + +/** + * Contains response data for the listByProfileNext operation. + */ +export type EndpointsListByProfileNextResponse = EndpointListResult & { + /** + * 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: EndpointListResult; + }; +}; + +/** + * Contains response data for the listResourceUsageNext operation. + */ +export type EndpointsListResourceUsageNextResponse = ResourceUsageListResult & { + /** + * 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: ResourceUsageListResult; + }; +}; + +/** + * Contains response data for the listByEndpoint operation. + */ +export type OriginsListByEndpointResponse = OriginListResult & { + /** + * 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: OriginListResult; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type OriginsGetResponse = Origin & { + /** + * 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: Origin; + }; +}; + +/** + * Contains response data for the create operation. + */ +export type OriginsCreateResponse = Origin & { + /** + * 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: Origin; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type OriginsUpdateResponse = Origin & { + /** + * 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: Origin; + }; +}; + +/** + * Contains response data for the beginCreate operation. + */ +export type OriginsBeginCreateResponse = Origin & { + /** + * 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: Origin; + }; +}; + +/** + * Contains response data for the beginUpdate operation. + */ +export type OriginsBeginUpdateResponse = Origin & { + /** + * 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: Origin; + }; +}; + +/** + * Contains response data for the listByEndpointNext operation. + */ +export type OriginsListByEndpointNextResponse = OriginListResult & { + /** + * 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: OriginListResult; + }; +}; + +/** + * Contains response data for the listByEndpoint operation. + */ +export type OriginGroupsListByEndpointResponse = OriginGroupListResult & { + /** + * 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: OriginGroupListResult; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type OriginGroupsGetResponse = OriginGroup & { + /** + * 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: OriginGroup; + }; +}; + +/** + * Contains response data for the create operation. + */ +export type OriginGroupsCreateResponse = OriginGroup & { + /** + * 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: OriginGroup; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type OriginGroupsUpdateResponse = OriginGroup & { + /** + * 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: OriginGroup; + }; +}; + +/** + * Contains response data for the beginCreate operation. + */ +export type OriginGroupsBeginCreateResponse = OriginGroup & { + /** + * 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: OriginGroup; + }; +}; + +/** + * Contains response data for the beginUpdate operation. + */ +export type OriginGroupsBeginUpdateResponse = OriginGroup & { + /** + * 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: OriginGroup; + }; +}; + +/** + * Contains response data for the listByEndpointNext operation. + */ +export type OriginGroupsListByEndpointNextResponse = OriginGroupListResult & { + /** + * 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: OriginGroupListResult; + }; +}; + +/** + * Contains response data for the listByEndpoint operation. + */ +export type CustomDomainsListByEndpointResponse = CustomDomainListResult & { + /** + * 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: CustomDomainListResult; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type CustomDomainsGetResponse = CustomDomain & { + /** + * 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: CustomDomain; + }; +}; + +/** + * Contains response data for the create operation. + */ +export type CustomDomainsCreateResponse = CustomDomain & { + /** + * 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: CustomDomain; + }; +}; + +/** + * Contains response data for the deleteMethod operation. + */ +export type CustomDomainsDeleteMethodResponse = CustomDomain & { + /** + * 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: CustomDomain; + }; +}; /** - * Defines values for OptimizationType. - * Possible values include: 'GeneralWebDelivery', 'GeneralMediaStreaming', - * 'VideoOnDemandMediaStreaming', 'LargeFileDownload', 'DynamicSiteAcceleration' - * @readonly - * @enum {string} + * Contains response data for the disableCustomHttps operation. */ -export type OptimizationType = 'GeneralWebDelivery' | 'GeneralMediaStreaming' | 'VideoOnDemandMediaStreaming' | 'LargeFileDownload' | 'DynamicSiteAcceleration'; +export type CustomDomainsDisableCustomHttpsResponse = CustomDomain & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for HealthProbeRequestType. - * Possible values include: 'NotSet', 'GET', 'HEAD' - * @readonly - * @enum {string} - */ -export type HealthProbeRequestType = 'NotSet' | 'GET' | 'HEAD'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: CustomDomain; + }; +}; /** - * Defines values for ProbeProtocol. - * Possible values include: 'NotSet', 'Http', 'Https' - * @readonly - * @enum {string} + * Contains response data for the enableCustomHttps operation. */ -export type ProbeProtocol = 'NotSet' | 'Http' | 'Https'; +export type CustomDomainsEnableCustomHttpsResponse = CustomDomain & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for ResponseBasedDetectedErrorTypes. - * Possible values include: 'None', 'TcpErrorsOnly', 'TcpAndHttpErrors' - * @readonly - * @enum {string} - */ -export type ResponseBasedDetectedErrorTypes = 'None' | 'TcpErrorsOnly' | 'TcpAndHttpErrors'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: CustomDomain; + }; +}; /** - * Defines values for EndpointResourceState. - * Possible values include: 'Creating', 'Deleting', 'Running', 'Starting', 'Stopped', 'Stopping' - * @readonly - * @enum {string} + * Contains response data for the beginCreate operation. */ -export type EndpointResourceState = 'Creating' | 'Deleting' | 'Running' | 'Starting' | 'Stopped' | 'Stopping'; +export type CustomDomainsBeginCreateResponse = CustomDomain & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for QueryStringCachingBehavior. - * Possible values include: 'IgnoreQueryString', 'BypassCaching', 'UseQueryString', 'NotSet' - * @readonly - * @enum {string} - */ -export type QueryStringCachingBehavior = 'IgnoreQueryString' | 'BypassCaching' | 'UseQueryString' | 'NotSet'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: CustomDomain; + }; +}; /** - * Defines values for GeoFilterActions. - * Possible values include: 'Block', 'Allow' - * @readonly - * @enum {string} + * Contains response data for the beginDeleteMethod operation. */ -export type GeoFilterActions = 'Block' | 'Allow'; +export type CustomDomainsBeginDeleteMethodResponse = CustomDomain & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for RemoteAddressOperator. - * Possible values include: 'Any', 'IPMatch', 'GeoMatch' - * @readonly - * @enum {string} - */ -export type RemoteAddressOperator = 'Any' | 'IPMatch' | 'GeoMatch'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: CustomDomain; + }; +}; /** - * Defines values for Transform. - * Possible values include: 'Lowercase', 'Uppercase' - * @readonly - * @enum {string} + * Contains response data for the beginDisableCustomHttps operation. */ -export type Transform = 'Lowercase' | 'Uppercase'; +export type CustomDomainsBeginDisableCustomHttpsResponse = CustomDomain & { + /** + * 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: CustomDomain; + }; +}; /** - * Defines values for QueryStringOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} + * Contains response data for the beginEnableCustomHttps operation. */ -export type QueryStringOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; +export type CustomDomainsBeginEnableCustomHttpsResponse = CustomDomain & { + /** + * 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: CustomDomain; + }; +}; /** - * Defines values for PostArgsOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} + * Contains response data for the listByEndpointNext operation. */ -export type PostArgsOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; +export type CustomDomainsListByEndpointNextResponse = CustomDomainListResult & { + /** + * 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: CustomDomainListResult; + }; +}; /** - * Defines values for RequestUriOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} + * Contains response data for the checkNameAvailability operation. */ -export type RequestUriOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; +export type CheckNameAvailabilityResponse = CheckNameAvailabilityOutput & { + /** + * 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: CheckNameAvailabilityOutput; + }; +}; /** - * Defines values for RequestHeaderOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} + * Contains response data for the checkNameAvailabilityWithSubscription operation. */ -export type RequestHeaderOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; +export type CheckNameAvailabilityWithSubscriptionResponse = CheckNameAvailabilityOutput & { + /** + * 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: CheckNameAvailabilityOutput; + }; +}; /** - * Defines values for RequestBodyOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} + * Contains response data for the validateProbe operation. */ -export type RequestBodyOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; +export type ValidateProbeResponse = ValidateProbeOutput & { + /** + * 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: ValidateProbeOutput; + }; +}; /** - * Defines values for UrlPathOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual', 'Wildcard' - * @readonly - * @enum {string} + * Contains response data for the list operation. */ -export type UrlPathOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual' | 'Wildcard'; +export type ResourceUsageListResponse = ResourceUsageListResult & { + /** + * 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: ResourceUsageListResult; + }; +}; /** - * Defines values for UrlFileExtensionOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} + * Contains response data for the listNext operation. */ -export type UrlFileExtensionOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; +export type ResourceUsageListNextResponse = ResourceUsageListResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for UrlFileNameOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} - */ -export type UrlFileNameOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: ResourceUsageListResult; + }; +}; /** - * Defines values for CookiesOperator. - * Possible values include: 'Any', 'Equal', 'Contains', 'BeginsWith', 'EndsWith', 'LessThan', - * 'LessThanOrEqual', 'GreaterThan', 'GreaterThanOrEqual' - * @readonly - * @enum {string} + * Contains response data for the list operation. */ -export type CookiesOperator = 'Any' | 'Equal' | 'Contains' | 'BeginsWith' | 'EndsWith' | 'LessThan' | 'LessThanOrEqual' | 'GreaterThan' | 'GreaterThanOrEqual'; +export type OperationsListResponse = OperationsListResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for RedirectType. - * Possible values include: 'Moved', 'Found', 'TemporaryRedirect', 'PermanentRedirect' - * @readonly - * @enum {string} - */ -export type RedirectType = 'Moved' | 'Found' | 'TemporaryRedirect' | 'PermanentRedirect'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: OperationsListResult; + }; +}; /** - * Defines values for DestinationProtocol. - * Possible values include: 'MatchRequest', 'Http', 'Https' - * @readonly - * @enum {string} + * Contains response data for the listNext operation. */ -export type DestinationProtocol = 'MatchRequest' | 'Http' | 'Https'; +export type OperationsListNextResponse = OperationsListResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for Algorithm. - * Possible values include: 'SHA256' - * @readonly - * @enum {string} - */ -export type Algorithm = 'SHA256'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: OperationsListResult; + }; +}; /** - * Defines values for ParamIndicator. - * Possible values include: 'Expires', 'KeyId', 'Signature' - * @readonly - * @enum {string} + * Contains response data for the list operation. */ -export type ParamIndicator = 'Expires' | 'KeyId' | 'Signature'; +export type EdgeNodesListResponse = EdgenodeResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for HeaderAction. - * Possible values include: 'Append', 'Overwrite', 'Delete' - * @readonly - * @enum {string} - */ -export type HeaderAction = 'Append' | 'Overwrite' | 'Delete'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: EdgenodeResult; + }; +}; /** - * Defines values for CacheBehavior. - * Possible values include: 'BypassCache', 'Override', 'SetIfMissing' - * @readonly - * @enum {string} + * Contains response data for the listNext operation. */ -export type CacheBehavior = 'BypassCache' | 'Override' | 'SetIfMissing'; +export type EdgeNodesListNextResponse = EdgenodeResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for QueryStringBehavior. - * Possible values include: 'Include', 'IncludeAll', 'Exclude', 'ExcludeAll' - * @readonly - * @enum {string} - */ -export type QueryStringBehavior = 'Include' | 'IncludeAll' | 'Exclude' | 'ExcludeAll'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: EdgenodeResult; + }; +}; /** - * Defines values for OriginResourceState. - * Possible values include: 'Creating', 'Active', 'Deleting' - * @readonly - * @enum {string} + * Contains response data for the listResourceUsage operation. */ -export type OriginResourceState = 'Creating' | 'Active' | 'Deleting'; +export type AFDProfilesListResourceUsageResponse = UsagesListResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for PrivateEndpointStatus. - * Possible values include: 'Pending', 'Approved', 'Rejected', 'Disconnected', 'Timeout' - * @readonly - * @enum {string} - */ -export type PrivateEndpointStatus = 'Pending' | 'Approved' | 'Rejected' | 'Disconnected' | 'Timeout'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: UsagesListResult; + }; +}; /** - * Defines values for OriginGroupResourceState. - * Possible values include: 'Creating', 'Active', 'Deleting' - * @readonly - * @enum {string} + * Contains response data for the checkHostNameAvailability operation. */ -export type OriginGroupResourceState = 'Creating' | 'Active' | 'Deleting'; +export type AFDProfilesCheckHostNameAvailabilityResponse = ValidateCustomDomainOutput & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for CustomDomainResourceState. - * Possible values include: 'Creating', 'Active', 'Deleting' - * @readonly - * @enum {string} - */ -export type CustomDomainResourceState = 'Creating' | 'Active' | 'Deleting'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: ValidateCustomDomainOutput; + }; +}; /** - * Defines values for CustomHttpsProvisioningState. - * Possible values include: 'Enabling', 'Enabled', 'Disabling', 'Disabled', 'Failed' - * @readonly - * @enum {string} + * Contains response data for the listResourceUsageNext operation. */ -export type CustomHttpsProvisioningState = 'Enabling' | 'Enabled' | 'Disabling' | 'Disabled' | 'Failed'; +export type AFDProfilesListResourceUsageNextResponse = UsagesListResult & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; -/** - * Defines values for CustomHttpsProvisioningSubstate. - * Possible values include: 'SubmittingDomainControlValidationRequest', - * 'PendingDomainControlValidationREquestApproval', 'DomainControlValidationRequestApproved', - * 'DomainControlValidationRequestRejected', 'DomainControlValidationRequestTimedOut', - * 'IssuingCertificate', 'DeployingCertificate', 'CertificateDeployed', 'DeletingCertificate', - * 'CertificateDeleted' - * @readonly - * @enum {string} - */ -export type CustomHttpsProvisioningSubstate = 'SubmittingDomainControlValidationRequest' | 'PendingDomainControlValidationREquestApproval' | 'DomainControlValidationRequestApproved' | 'DomainControlValidationRequestRejected' | 'DomainControlValidationRequestTimedOut' | 'IssuingCertificate' | 'DeployingCertificate' | 'CertificateDeployed' | 'DeletingCertificate' | 'CertificateDeleted'; + /** + * The response body as parsed JSON or XML + */ + parsedBody: UsagesListResult; + }; +}; /** - * Defines values for ProtocolType. - * Possible values include: 'ServerNameIndication', 'IPBased' - * @readonly - * @enum {string} + * Contains response data for the listByProfile operation. */ -export type ProtocolType = 'ServerNameIndication' | 'IPBased'; +export type AFDCustomDomainsListByProfileResponse = AFDDomainListResult & { + /** + * 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: AFDDomainListResult; + }; +}; /** - * Defines values for MinimumTlsVersion. - * Possible values include: 'None', 'TLS10', 'TLS12' - * @readonly - * @enum {string} + * Contains response data for the get operation. */ -export type MinimumTlsVersion = 'None' | 'TLS10' | 'TLS12'; +export type AFDCustomDomainsGetResponse = AFDDomain & { + /** + * 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: AFDDomain; + }; +}; /** - * Defines values for CertificateType. - * Possible values include: 'Shared', 'Dedicated' - * @readonly - * @enum {string} + * Contains response data for the create operation. */ -export type CertificateType = 'Shared' | 'Dedicated'; +export type AFDCustomDomainsCreateResponse = AFDDomain & { + /** + * 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: AFDDomain; + }; +}; /** - * Defines values for ResourceType. - * Possible values include: 'Microsoft.Cdn/Profiles/Endpoints' - * @readonly - * @enum {string} + * Contains response data for the update operation. */ -export type ResourceType = 'Microsoft.Cdn/Profiles/Endpoints'; +export type AFDCustomDomainsUpdateResponse = AFDDomain & { + /** + * 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: AFDDomain; + }; +}; /** - * Defines values for PolicyEnabledState. - * Possible values include: 'Disabled', 'Enabled' - * @readonly - * @enum {string} + * Contains response data for the refreshValidationToken operation. */ -export type PolicyEnabledState = 'Disabled' | 'Enabled'; +export type AFDCustomDomainsRefreshValidationTokenResponse = ValidationToken & { + /** + * 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: ValidationToken; + }; +}; /** - * Defines values for PolicyMode. - * Possible values include: 'Prevention', 'Detection' - * @readonly - * @enum {string} + * Contains response data for the beginCreate operation. */ -export type PolicyMode = 'Prevention' | 'Detection'; +export type AFDCustomDomainsBeginCreateResponse = AFDDomain & { + /** + * 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: AFDDomain; + }; +}; /** - * Defines values for CustomRuleEnabledState. - * Possible values include: 'Disabled', 'Enabled' - * @readonly - * @enum {string} + * Contains response data for the beginUpdate operation. */ -export type CustomRuleEnabledState = 'Disabled' | 'Enabled'; +export type AFDCustomDomainsBeginUpdateResponse = AFDDomain & { + /** + * 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: AFDDomain; + }; +}; /** - * Defines values for MatchVariable. - * Possible values include: 'RemoteAddr', 'SocketAddr', 'RequestMethod', 'RequestHeader', - * 'RequestUri', 'QueryString', 'RequestBody', 'Cookies', 'PostArgs' - * @readonly - * @enum {string} + * Contains response data for the beginRefreshValidationToken operation. */ -export type MatchVariable = 'RemoteAddr' | 'SocketAddr' | 'RequestMethod' | 'RequestHeader' | 'RequestUri' | 'QueryString' | 'RequestBody' | 'Cookies' | 'PostArgs'; +export type AFDCustomDomainsBeginRefreshValidationTokenResponse = ValidationToken & { + /** + * 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: ValidationToken; + }; +}; /** - * Defines values for Operator. - * Possible values include: 'Any', 'IPMatch', 'GeoMatch', 'Equal', 'Contains', 'LessThan', - * 'GreaterThan', 'LessThanOrEqual', 'GreaterThanOrEqual', 'BeginsWith', 'EndsWith', 'RegEx' - * @readonly - * @enum {string} + * Contains response data for the listByProfileNext operation. */ -export type Operator = 'Any' | 'IPMatch' | 'GeoMatch' | 'Equal' | 'Contains' | 'LessThan' | 'GreaterThan' | 'LessThanOrEqual' | 'GreaterThanOrEqual' | 'BeginsWith' | 'EndsWith' | 'RegEx'; +export type AFDCustomDomainsListByProfileNextResponse = AFDDomainListResult & { + /** + * 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: AFDDomainListResult; + }; +}; /** - * Defines values for TransformType. - * Possible values include: 'Lowercase', 'Uppercase', 'Trim', 'UrlDecode', 'UrlEncode', - * 'RemoveNulls' - * @readonly - * @enum {string} + * Contains response data for the listByProfile operation. */ -export type TransformType = 'Lowercase' | 'Uppercase' | 'Trim' | 'UrlDecode' | 'UrlEncode' | 'RemoveNulls'; +export type AFDEndpointsListByProfileResponse = AFDEndpointListResult & { + /** + * 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: AFDEndpointListResult; + }; +}; /** - * Defines values for ActionType. - * Possible values include: 'Allow', 'Block', 'Log', 'Redirect' - * @readonly - * @enum {string} + * Contains response data for the get operation. */ -export type ActionType = 'Allow' | 'Block' | 'Log' | 'Redirect'; +export type AFDEndpointsGetResponse = AFDEndpoint & { + /** + * 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: AFDEndpoint; + }; +}; /** - * Defines values for ManagedRuleEnabledState. - * Possible values include: 'Disabled', 'Enabled' - * @readonly - * @enum {string} + * Contains response data for the create operation. */ -export type ManagedRuleEnabledState = 'Disabled' | 'Enabled'; +export type AFDEndpointsCreateResponse = AFDEndpoint & { + /** + * 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: AFDEndpoint; + }; +}; /** - * Defines values for ProvisioningState. - * Possible values include: 'Creating', 'Succeeded', 'Failed' - * @readonly - * @enum {string} + * Contains response data for the update operation. */ -export type ProvisioningState = 'Creating' | 'Succeeded' | 'Failed'; +export type AFDEndpointsUpdateResponse = AFDEndpoint & { + /** + * 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: AFDEndpoint; + }; +}; /** - * Defines values for PolicyResourceState. - * Possible values include: 'Creating', 'Enabling', 'Enabled', 'Disabling', 'Disabled', 'Deleting' - * @readonly - * @enum {string} + * Contains response data for the listResourceUsage operation. */ -export type PolicyResourceState = 'Creating' | 'Enabling' | 'Enabled' | 'Disabling' | 'Disabled' | 'Deleting'; +export type AFDEndpointsListResourceUsageResponse = UsagesListResult & { + /** + * 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: UsagesListResult; + }; +}; /** - * Defines values for Odatatype. - * Possible values include: '#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlSigningActionParameters' - * @readonly - * @enum {string} + * Contains response data for the validateCustomDomain operation. */ -export type Odatatype = '#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlSigningActionParameters'; +export type AFDEndpointsValidateCustomDomainResponse = ValidateCustomDomainOutput & { + /** + * 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: ValidateCustomDomainOutput; + }; +}; /** - * Contains response data for the list operation. + * Contains response data for the beginCreate operation. */ -export type ProfilesListResponse = ProfileListResult & { +export type AFDEndpointsBeginCreateResponse = AFDEndpoint & { /** * The underlying HTTP response. */ @@ -2880,14 +6257,14 @@ export type ProfilesListResponse = ProfileListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ProfileListResult; + parsedBody: AFDEndpoint; }; }; /** - * Contains response data for the listByResourceGroup operation. + * Contains response data for the beginUpdate operation. */ -export type ProfilesListByResourceGroupResponse = ProfileListResult & { +export type AFDEndpointsBeginUpdateResponse = AFDEndpoint & { /** * The underlying HTTP response. */ @@ -2900,14 +6277,14 @@ export type ProfilesListByResourceGroupResponse = ProfileListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ProfileListResult; + parsedBody: AFDEndpoint; }; }; /** - * Contains response data for the get operation. + * Contains response data for the listByProfileNext operation. */ -export type ProfilesGetResponse = Profile & { +export type AFDEndpointsListByProfileNextResponse = AFDEndpointListResult & { /** * The underlying HTTP response. */ @@ -2920,14 +6297,14 @@ export type ProfilesGetResponse = Profile & { /** * The response body as parsed JSON or XML */ - parsedBody: Profile; + parsedBody: AFDEndpointListResult; }; }; /** - * Contains response data for the create operation. + * Contains response data for the listResourceUsageNext operation. */ -export type ProfilesCreateResponse = Profile & { +export type AFDEndpointsListResourceUsageNextResponse = UsagesListResult & { /** * The underlying HTTP response. */ @@ -2940,14 +6317,14 @@ export type ProfilesCreateResponse = Profile & { /** * The response body as parsed JSON or XML */ - parsedBody: Profile; + parsedBody: UsagesListResult; }; }; /** - * Contains response data for the update operation. + * Contains response data for the listByProfile operation. */ -export type ProfilesUpdateResponse = Profile & { +export type AFDOriginGroupsListByProfileResponse = AFDOriginGroupListResult & { /** * The underlying HTTP response. */ @@ -2960,14 +6337,14 @@ export type ProfilesUpdateResponse = Profile & { /** * The response body as parsed JSON or XML */ - parsedBody: Profile; + parsedBody: AFDOriginGroupListResult; }; }; /** - * Contains response data for the generateSsoUri operation. + * Contains response data for the get operation. */ -export type ProfilesGenerateSsoUriResponse = SsoUri & { +export type AFDOriginGroupsGetResponse = AFDOriginGroup & { /** * The underlying HTTP response. */ @@ -2980,14 +6357,14 @@ export type ProfilesGenerateSsoUriResponse = SsoUri & { /** * The response body as parsed JSON or XML */ - parsedBody: SsoUri; + parsedBody: AFDOriginGroup; }; }; /** - * Contains response data for the listSupportedOptimizationTypes operation. + * Contains response data for the create operation. */ -export type ProfilesListSupportedOptimizationTypesResponse = SupportedOptimizationTypesListResult & { +export type AFDOriginGroupsCreateResponse = AFDOriginGroup & { /** * The underlying HTTP response. */ @@ -3000,14 +6377,14 @@ export type ProfilesListSupportedOptimizationTypesResponse = SupportedOptimizati /** * The response body as parsed JSON or XML */ - parsedBody: SupportedOptimizationTypesListResult; + parsedBody: AFDOriginGroup; }; }; /** - * Contains response data for the listResourceUsage operation. + * Contains response data for the update operation. */ -export type ProfilesListResourceUsageResponse = ResourceUsageListResult & { +export type AFDOriginGroupsUpdateResponse = AFDOriginGroup & { /** * The underlying HTTP response. */ @@ -3020,14 +6397,14 @@ export type ProfilesListResourceUsageResponse = ResourceUsageListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ResourceUsageListResult; + parsedBody: AFDOriginGroup; }; }; /** - * Contains response data for the beginCreate operation. + * Contains response data for the listResourceUsage operation. */ -export type ProfilesBeginCreateResponse = Profile & { +export type AFDOriginGroupsListResourceUsageResponse = UsagesListResult & { /** * The underlying HTTP response. */ @@ -3040,14 +6417,14 @@ export type ProfilesBeginCreateResponse = Profile & { /** * The response body as parsed JSON or XML */ - parsedBody: Profile; + parsedBody: UsagesListResult; }; }; /** - * Contains response data for the beginUpdate operation. + * Contains response data for the beginCreate operation. */ -export type ProfilesBeginUpdateResponse = Profile & { +export type AFDOriginGroupsBeginCreateResponse = AFDOriginGroup & { /** * The underlying HTTP response. */ @@ -3060,14 +6437,14 @@ export type ProfilesBeginUpdateResponse = Profile & { /** * The response body as parsed JSON or XML */ - parsedBody: Profile; + parsedBody: AFDOriginGroup; }; }; /** - * Contains response data for the listNext operation. + * Contains response data for the beginUpdate operation. */ -export type ProfilesListNextResponse = ProfileListResult & { +export type AFDOriginGroupsBeginUpdateResponse = AFDOriginGroup & { /** * The underlying HTTP response. */ @@ -3080,14 +6457,14 @@ export type ProfilesListNextResponse = ProfileListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ProfileListResult; + parsedBody: AFDOriginGroup; }; }; /** - * Contains response data for the listByResourceGroupNext operation. + * Contains response data for the listByProfileNext operation. */ -export type ProfilesListByResourceGroupNextResponse = ProfileListResult & { +export type AFDOriginGroupsListByProfileNextResponse = AFDOriginGroupListResult & { /** * The underlying HTTP response. */ @@ -3100,14 +6477,14 @@ export type ProfilesListByResourceGroupNextResponse = ProfileListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ProfileListResult; + parsedBody: AFDOriginGroupListResult; }; }; /** * Contains response data for the listResourceUsageNext operation. */ -export type ProfilesListResourceUsageNextResponse = ResourceUsageListResult & { +export type AFDOriginGroupsListResourceUsageNextResponse = UsagesListResult & { /** * The underlying HTTP response. */ @@ -3120,14 +6497,14 @@ export type ProfilesListResourceUsageNextResponse = ResourceUsageListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ResourceUsageListResult; + parsedBody: UsagesListResult; }; }; /** - * Contains response data for the listByProfile operation. + * Contains response data for the listByOriginGroup operation. */ -export type EndpointsListByProfileResponse = EndpointListResult & { +export type AFDOriginsListByOriginGroupResponse = AFDOriginListResult & { /** * The underlying HTTP response. */ @@ -3140,14 +6517,14 @@ export type EndpointsListByProfileResponse = EndpointListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: EndpointListResult; + parsedBody: AFDOriginListResult; }; }; /** * Contains response data for the get operation. */ -export type EndpointsGetResponse = Endpoint & { +export type AFDOriginsGetResponse = AFDOrigin & { /** * The underlying HTTP response. */ @@ -3160,14 +6537,14 @@ export type EndpointsGetResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: AFDOrigin; }; }; /** * Contains response data for the create operation. */ -export type EndpointsCreateResponse = Endpoint & { +export type AFDOriginsCreateResponse = AFDOrigin & { /** * The underlying HTTP response. */ @@ -3180,14 +6557,14 @@ export type EndpointsCreateResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: AFDOrigin; }; }; /** * Contains response data for the update operation. */ -export type EndpointsUpdateResponse = Endpoint & { +export type AFDOriginsUpdateResponse = AFDOrigin & { /** * The underlying HTTP response. */ @@ -3200,14 +6577,14 @@ export type EndpointsUpdateResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: AFDOrigin; }; }; /** - * Contains response data for the start operation. + * Contains response data for the beginCreate operation. */ -export type EndpointsStartResponse = Endpoint & { +export type AFDOriginsBeginCreateResponse = AFDOrigin & { /** * The underlying HTTP response. */ @@ -3220,14 +6597,14 @@ export type EndpointsStartResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: AFDOrigin; }; }; /** - * Contains response data for the stop operation. + * Contains response data for the beginUpdate operation. */ -export type EndpointsStopResponse = Endpoint & { +export type AFDOriginsBeginUpdateResponse = AFDOrigin & { /** * The underlying HTTP response. */ @@ -3240,14 +6617,14 @@ export type EndpointsStopResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: AFDOrigin; }; }; /** - * Contains response data for the validateCustomDomain operation. + * Contains response data for the listByOriginGroupNext operation. */ -export type EndpointsValidateCustomDomainResponse = ValidateCustomDomainOutput & { +export type AFDOriginsListByOriginGroupNextResponse = AFDOriginListResult & { /** * The underlying HTTP response. */ @@ -3260,14 +6637,14 @@ export type EndpointsValidateCustomDomainResponse = ValidateCustomDomainOutput & /** * The response body as parsed JSON or XML */ - parsedBody: ValidateCustomDomainOutput; + parsedBody: AFDOriginListResult; }; }; /** - * Contains response data for the listResourceUsage operation. + * Contains response data for the listByEndpoint operation. */ -export type EndpointsListResourceUsageResponse = ResourceUsageListResult & { +export type RoutesListByEndpointResponse = RouteListResult & { /** * The underlying HTTP response. */ @@ -3280,14 +6657,14 @@ export type EndpointsListResourceUsageResponse = ResourceUsageListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ResourceUsageListResult; + parsedBody: RouteListResult; }; }; /** - * Contains response data for the beginCreate operation. + * Contains response data for the get operation. */ -export type EndpointsBeginCreateResponse = Endpoint & { +export type RoutesGetResponse = Route & { /** * The underlying HTTP response. */ @@ -3300,14 +6677,14 @@ export type EndpointsBeginCreateResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: Route; }; }; /** - * Contains response data for the beginUpdate operation. + * Contains response data for the create operation. */ -export type EndpointsBeginUpdateResponse = Endpoint & { +export type RoutesCreateResponse = Route & { /** * The underlying HTTP response. */ @@ -3320,14 +6697,14 @@ export type EndpointsBeginUpdateResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: Route; }; }; /** - * Contains response data for the beginStart operation. + * Contains response data for the update operation. */ -export type EndpointsBeginStartResponse = Endpoint & { +export type RoutesUpdateResponse = Route & { /** * The underlying HTTP response. */ @@ -3340,14 +6717,14 @@ export type EndpointsBeginStartResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: Route; }; }; /** - * Contains response data for the beginStop operation. + * Contains response data for the beginCreate operation. */ -export type EndpointsBeginStopResponse = Endpoint & { +export type RoutesBeginCreateResponse = Route & { /** * The underlying HTTP response. */ @@ -3360,14 +6737,14 @@ export type EndpointsBeginStopResponse = Endpoint & { /** * The response body as parsed JSON or XML */ - parsedBody: Endpoint; + parsedBody: Route; }; }; /** - * Contains response data for the listByProfileNext operation. + * Contains response data for the beginUpdate operation. */ -export type EndpointsListByProfileNextResponse = EndpointListResult & { +export type RoutesBeginUpdateResponse = Route & { /** * The underlying HTTP response. */ @@ -3380,14 +6757,14 @@ export type EndpointsListByProfileNextResponse = EndpointListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: EndpointListResult; + parsedBody: Route; }; }; /** - * Contains response data for the listResourceUsageNext operation. + * Contains response data for the listByEndpointNext operation. */ -export type EndpointsListResourceUsageNextResponse = ResourceUsageListResult & { +export type RoutesListByEndpointNextResponse = RouteListResult & { /** * The underlying HTTP response. */ @@ -3400,14 +6777,14 @@ export type EndpointsListResourceUsageNextResponse = ResourceUsageListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ResourceUsageListResult; + parsedBody: RouteListResult; }; }; /** - * Contains response data for the listByEndpoint operation. + * Contains response data for the listByProfile operation. */ -export type OriginsListByEndpointResponse = OriginListResult & { +export type RuleSetsListByProfileResponse = RuleSetListResult & { /** * The underlying HTTP response. */ @@ -3420,14 +6797,14 @@ export type OriginsListByEndpointResponse = OriginListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginListResult; + parsedBody: RuleSetListResult; }; }; /** * Contains response data for the get operation. */ -export type OriginsGetResponse = Origin & { +export type RuleSetsGetResponse = RuleSet & { /** * The underlying HTTP response. */ @@ -3440,14 +6817,14 @@ export type OriginsGetResponse = Origin & { /** * The response body as parsed JSON or XML */ - parsedBody: Origin; + parsedBody: RuleSet; }; }; /** * Contains response data for the create operation. */ -export type OriginsCreateResponse = Origin & { +export type RuleSetsCreateResponse = RuleSet & { /** * The underlying HTTP response. */ @@ -3460,14 +6837,14 @@ export type OriginsCreateResponse = Origin & { /** * The response body as parsed JSON or XML */ - parsedBody: Origin; + parsedBody: RuleSet; }; }; /** - * Contains response data for the update operation. + * Contains response data for the listResourceUsage operation. */ -export type OriginsUpdateResponse = Origin & { +export type RuleSetsListResourceUsageResponse = UsagesListResult & { /** * The underlying HTTP response. */ @@ -3480,14 +6857,14 @@ export type OriginsUpdateResponse = Origin & { /** * The response body as parsed JSON or XML */ - parsedBody: Origin; + parsedBody: UsagesListResult; }; }; /** * Contains response data for the beginCreate operation. */ -export type OriginsBeginCreateResponse = Origin & { +export type RuleSetsBeginCreateResponse = RuleSet & { /** * The underlying HTTP response. */ @@ -3500,14 +6877,14 @@ export type OriginsBeginCreateResponse = Origin & { /** * The response body as parsed JSON or XML */ - parsedBody: Origin; + parsedBody: RuleSet; }; }; /** - * Contains response data for the beginUpdate operation. + * Contains response data for the listByProfileNext operation. */ -export type OriginsBeginUpdateResponse = Origin & { +export type RuleSetsListByProfileNextResponse = RuleSetListResult & { /** * The underlying HTTP response. */ @@ -3520,14 +6897,14 @@ export type OriginsBeginUpdateResponse = Origin & { /** * The response body as parsed JSON or XML */ - parsedBody: Origin; + parsedBody: RuleSetListResult; }; }; /** - * Contains response data for the listByEndpointNext operation. + * Contains response data for the listResourceUsageNext operation. */ -export type OriginsListByEndpointNextResponse = OriginListResult & { +export type RuleSetsListResourceUsageNextResponse = UsagesListResult & { /** * The underlying HTTP response. */ @@ -3540,14 +6917,14 @@ export type OriginsListByEndpointNextResponse = OriginListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginListResult; + parsedBody: UsagesListResult; }; }; /** - * Contains response data for the listByEndpoint operation. + * Contains response data for the listByRuleSet operation. */ -export type OriginGroupsListByEndpointResponse = OriginGroupListResult & { +export type RulesListByRuleSetResponse = RuleListResult & { /** * The underlying HTTP response. */ @@ -3560,14 +6937,14 @@ export type OriginGroupsListByEndpointResponse = OriginGroupListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginGroupListResult; + parsedBody: RuleListResult; }; }; /** * Contains response data for the get operation. */ -export type OriginGroupsGetResponse = OriginGroup & { +export type RulesGetResponse = Rule & { /** * The underlying HTTP response. */ @@ -3580,14 +6957,14 @@ export type OriginGroupsGetResponse = OriginGroup & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginGroup; + parsedBody: Rule; }; }; /** * Contains response data for the create operation. */ -export type OriginGroupsCreateResponse = OriginGroup & { +export type RulesCreateResponse = Rule & { /** * The underlying HTTP response. */ @@ -3600,14 +6977,14 @@ export type OriginGroupsCreateResponse = OriginGroup & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginGroup; + parsedBody: Rule; }; }; /** * Contains response data for the update operation. */ -export type OriginGroupsUpdateResponse = OriginGroup & { +export type RulesUpdateResponse = Rule & { /** * The underlying HTTP response. */ @@ -3620,14 +6997,14 @@ export type OriginGroupsUpdateResponse = OriginGroup & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginGroup; + parsedBody: Rule; }; }; /** * Contains response data for the beginCreate operation. */ -export type OriginGroupsBeginCreateResponse = OriginGroup & { +export type RulesBeginCreateResponse = Rule & { /** * The underlying HTTP response. */ @@ -3640,14 +7017,14 @@ export type OriginGroupsBeginCreateResponse = OriginGroup & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginGroup; + parsedBody: Rule; }; }; /** * Contains response data for the beginUpdate operation. */ -export type OriginGroupsBeginUpdateResponse = OriginGroup & { +export type RulesBeginUpdateResponse = Rule & { /** * The underlying HTTP response. */ @@ -3660,14 +7037,14 @@ export type OriginGroupsBeginUpdateResponse = OriginGroup & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginGroup; + parsedBody: Rule; }; }; /** - * Contains response data for the listByEndpointNext operation. + * Contains response data for the listByRuleSetNext operation. */ -export type OriginGroupsListByEndpointNextResponse = OriginGroupListResult & { +export type RulesListByRuleSetNextResponse = RuleListResult & { /** * The underlying HTTP response. */ @@ -3680,14 +7057,14 @@ export type OriginGroupsListByEndpointNextResponse = OriginGroupListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: OriginGroupListResult; + parsedBody: RuleListResult; }; }; /** - * Contains response data for the listByEndpoint operation. + * Contains response data for the listByProfile operation. */ -export type CustomDomainsListByEndpointResponse = CustomDomainListResult & { +export type SecurityPoliciesListByProfileResponse = SecurityPolicyListResult & { /** * The underlying HTTP response. */ @@ -3700,14 +7077,14 @@ export type CustomDomainsListByEndpointResponse = CustomDomainListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomainListResult; + parsedBody: SecurityPolicyListResult; }; }; /** * Contains response data for the get operation. */ -export type CustomDomainsGetResponse = CustomDomain & { +export type SecurityPoliciesGetResponse = SecurityPolicy & { /** * The underlying HTTP response. */ @@ -3720,14 +7097,14 @@ export type CustomDomainsGetResponse = CustomDomain & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomain; + parsedBody: SecurityPolicy; }; }; /** * Contains response data for the create operation. */ -export type CustomDomainsCreateResponse = CustomDomain & { +export type SecurityPoliciesCreateResponse = SecurityPolicy & { /** * The underlying HTTP response. */ @@ -3740,14 +7117,14 @@ export type CustomDomainsCreateResponse = CustomDomain & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomain; + parsedBody: SecurityPolicy; }; }; /** - * Contains response data for the deleteMethod operation. + * Contains response data for the patch operation. */ -export type CustomDomainsDeleteMethodResponse = CustomDomain & { +export type SecurityPoliciesPatchResponse = SecurityPolicy & { /** * The underlying HTTP response. */ @@ -3760,14 +7137,14 @@ export type CustomDomainsDeleteMethodResponse = CustomDomain & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomain; + parsedBody: SecurityPolicy; }; }; /** - * Contains response data for the disableCustomHttps operation. + * Contains response data for the beginCreate operation. */ -export type CustomDomainsDisableCustomHttpsResponse = CustomDomain & { +export type SecurityPoliciesBeginCreateResponse = SecurityPolicy & { /** * The underlying HTTP response. */ @@ -3780,14 +7157,14 @@ export type CustomDomainsDisableCustomHttpsResponse = CustomDomain & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomain; + parsedBody: SecurityPolicy; }; }; /** - * Contains response data for the enableCustomHttps operation. + * Contains response data for the beginPatch operation. */ -export type CustomDomainsEnableCustomHttpsResponse = CustomDomain & { +export type SecurityPoliciesBeginPatchResponse = SecurityPolicy & { /** * The underlying HTTP response. */ @@ -3800,14 +7177,14 @@ export type CustomDomainsEnableCustomHttpsResponse = CustomDomain & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomain; + parsedBody: SecurityPolicy; }; }; /** - * Contains response data for the beginCreate operation. + * Contains response data for the listByProfileNext operation. */ -export type CustomDomainsBeginCreateResponse = CustomDomain & { +export type SecurityPoliciesListByProfileNextResponse = SecurityPolicyListResult & { /** * The underlying HTTP response. */ @@ -3820,14 +7197,14 @@ export type CustomDomainsBeginCreateResponse = CustomDomain & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomain; + parsedBody: SecurityPolicyListResult; }; }; /** - * Contains response data for the beginDeleteMethod operation. + * Contains response data for the listByProfile operation. */ -export type CustomDomainsBeginDeleteMethodResponse = CustomDomain & { +export type SecretsListByProfileResponse = SecretListResult & { /** * The underlying HTTP response. */ @@ -3840,14 +7217,14 @@ export type CustomDomainsBeginDeleteMethodResponse = CustomDomain & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomain; + parsedBody: SecretListResult; }; }; /** - * Contains response data for the listByEndpointNext operation. + * Contains response data for the get operation. */ -export type CustomDomainsListByEndpointNextResponse = CustomDomainListResult & { +export type SecretsGetResponse = Secret & { /** * The underlying HTTP response. */ @@ -3860,14 +7237,14 @@ export type CustomDomainsListByEndpointNextResponse = CustomDomainListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: CustomDomainListResult; + parsedBody: Secret; }; }; /** - * Contains response data for the checkNameAvailability operation. + * Contains response data for the create operation. */ -export type CheckNameAvailabilityResponse = CheckNameAvailabilityOutput & { +export type SecretsCreateResponse = Secret & { /** * The underlying HTTP response. */ @@ -3880,14 +7257,14 @@ export type CheckNameAvailabilityResponse = CheckNameAvailabilityOutput & { /** * The response body as parsed JSON or XML */ - parsedBody: CheckNameAvailabilityOutput; + parsedBody: Secret; }; }; /** - * Contains response data for the checkNameAvailabilityWithSubscription operation. + * Contains response data for the update operation. */ -export type CheckNameAvailabilityWithSubscriptionResponse = CheckNameAvailabilityOutput & { +export type SecretsUpdateResponse = Secret & { /** * The underlying HTTP response. */ @@ -3900,14 +7277,14 @@ export type CheckNameAvailabilityWithSubscriptionResponse = CheckNameAvailabilit /** * The response body as parsed JSON or XML */ - parsedBody: CheckNameAvailabilityOutput; + parsedBody: Secret; }; }; /** - * Contains response data for the validateProbe operation. + * Contains response data for the beginCreate operation. */ -export type ValidateProbeResponse = ValidateProbeOutput & { +export type SecretsBeginCreateResponse = Secret & { /** * The underlying HTTP response. */ @@ -3920,14 +7297,14 @@ export type ValidateProbeResponse = ValidateProbeOutput & { /** * The response body as parsed JSON or XML */ - parsedBody: ValidateProbeOutput; + parsedBody: Secret; }; }; /** - * Contains response data for the list operation. + * Contains response data for the beginUpdate operation. */ -export type ResourceUsageListResponse = ResourceUsageListResult & { +export type SecretsBeginUpdateResponse = Secret & { /** * The underlying HTTP response. */ @@ -3940,14 +7317,14 @@ export type ResourceUsageListResponse = ResourceUsageListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ResourceUsageListResult; + parsedBody: Secret; }; }; /** - * Contains response data for the listNext operation. + * Contains response data for the listByProfileNext operation. */ -export type ResourceUsageListNextResponse = ResourceUsageListResult & { +export type SecretsListByProfileNextResponse = SecretListResult & { /** * The underlying HTTP response. */ @@ -3960,14 +7337,14 @@ export type ResourceUsageListNextResponse = ResourceUsageListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: ResourceUsageListResult; + parsedBody: SecretListResult; }; }; /** - * Contains response data for the list operation. + * Contains response data for the secretMethod operation. */ -export type OperationsListResponse = OperationsListResult & { +export type ValidateSecretMethodResponse = ValidateSecretOutput & { /** * The underlying HTTP response. */ @@ -3980,14 +7357,14 @@ export type OperationsListResponse = OperationsListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: OperationsListResult; + parsedBody: ValidateSecretOutput; }; }; /** - * Contains response data for the listNext operation. + * Contains response data for the getLogAnalyticsMetrics operation. */ -export type OperationsListNextResponse = OperationsListResult & { +export type LogAnalyticsGetLogAnalyticsMetricsResponse = MetricsResponse & { /** * The underlying HTTP response. */ @@ -4000,14 +7377,14 @@ export type OperationsListNextResponse = OperationsListResult & { /** * The response body as parsed JSON or XML */ - parsedBody: OperationsListResult; + parsedBody: MetricsResponse; }; }; /** - * Contains response data for the list operation. + * Contains response data for the getLogAnalyticsRankings operation. */ -export type EdgeNodesListResponse = EdgenodeResult & { +export type LogAnalyticsGetLogAnalyticsRankingsResponse = RankingsResponse & { /** * The underlying HTTP response. */ @@ -4020,14 +7397,14 @@ export type EdgeNodesListResponse = EdgenodeResult & { /** * The response body as parsed JSON or XML */ - parsedBody: EdgenodeResult; + parsedBody: RankingsResponse; }; }; /** - * Contains response data for the listNext operation. + * Contains response data for the getLogAnalyticsLocations operation. */ -export type EdgeNodesListNextResponse = EdgenodeResult & { +export type LogAnalyticsGetLogAnalyticsLocationsResponse = ContinentsResponse & { /** * The underlying HTTP response. */ @@ -4040,7 +7417,67 @@ export type EdgeNodesListNextResponse = EdgenodeResult & { /** * The response body as parsed JSON or XML */ - parsedBody: EdgenodeResult; + parsedBody: ContinentsResponse; + }; +}; + +/** + * Contains response data for the getLogAnalyticsResources operation. + */ +export type LogAnalyticsGetLogAnalyticsResourcesResponse = ResourcesResponse & { + /** + * 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: ResourcesResponse; + }; +}; + +/** + * Contains response data for the getWafLogAnalyticsMetrics operation. + */ +export type LogAnalyticsGetWafLogAnalyticsMetricsResponse = WafMetricsResponse & { + /** + * 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: WafMetricsResponse; + }; +}; + +/** + * Contains response data for the getWafLogAnalyticsRankings operation. + */ +export type LogAnalyticsGetWafLogAnalyticsRankingsResponse = WafRankingsResponse & { + /** + * 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: WafRankingsResponse; }; }; diff --git a/sdk/cdn/arm-cdn/src/models/logAnalyticsMappers.ts b/sdk/cdn/arm-cdn/src/models/logAnalyticsMappers.ts new file mode 100644 index 000000000000..71e84e2bb7b5 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/logAnalyticsMappers.ts @@ -0,0 +1,35 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AfdErrorResponse, + ContinentsResponse, + ContinentsResponseContinentsItem, + ContinentsResponseCountryOrRegionsItem, + ErrorResponse, + MetricsResponse, + MetricsResponseSeriesItem, + MetricsResponseSeriesItemDataItem, + MetricsResponseSeriesItemGroupsItem, + RankingsResponse, + RankingsResponseTablesItem, + RankingsResponseTablesItemDataItem, + RankingsResponseTablesItemDataItemMetricsItem, + ResourcesResponse, + ResourcesResponseCustomDomainsItem, + ResourcesResponseEndpointsItem, + ResourcesResponseEndpointsItemCustomDomainsItem, + WafMetricsResponse, + WafMetricsResponseSeriesItem, + WafMetricsResponseSeriesItemDataItem, + WafMetricsResponseSeriesItemGroupsItem, + WafRankingsResponse, + WafRankingsResponseDataItem, + WafRankingsResponseDataItemMetricsItem +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/managedRuleSetsMappers.ts b/sdk/cdn/arm-cdn/src/models/managedRuleSetsMappers.ts index 26e75df89001..90b7dcf7cc09 100644 --- a/sdk/cdn/arm-cdn/src/models/managedRuleSetsMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/managedRuleSetsMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,15 +8,27 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, CdnEndpoint, + CdnManagedHttpsParameters, CdnWebApplicationFirewallPolicy, CdnWebApplicationFirewallPolicyPatchParameters, CidrIpAddress, CookiesMatchConditionParameters, CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -42,6 +54,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, Endpoint, EndpointPropertiesUpdateParametersDeliveryPolicy, @@ -55,7 +68,10 @@ export { HttpVersionMatchConditionParameters, IpAddressGroup, IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -67,6 +83,8 @@ export { MatchCondition, Origin, OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginUpdateParameters, PolicySettings, @@ -86,7 +104,17 @@ export { Resource, ResourceReference, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -98,5 +126,7 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, - UrlSigningParamIdentifier + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/mappers.ts b/sdk/cdn/arm-cdn/src/models/mappers.ts index 7a8abf0ac0e1..00ee89695333 100644 --- a/sdk/cdn/arm-cdn/src/models/mappers.ts +++ b/sdk/cdn/arm-cdn/src/models/mappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -54,6 +54,14 @@ export const Resource: msRest.CompositeMapper = { type: { name: "String" } + }, + systemData: { + readOnly: true, + serializedName: "systemData", + type: { + name: "Composite", + className: "SystemData" + } } } } @@ -116,6 +124,13 @@ export const Profile: msRest.CompositeMapper = { type: { name: "String" } + }, + frontdoorId: { + readOnly: true, + serializedName: "properties.frontdoorId", + type: { + name: "String" + } } } } @@ -2193,14 +2208,10 @@ export const UrlSigningActionParameters: msRest.CompositeMapper = { className: "UrlSigningActionParameters", modelProperties: { odatatype: { - serializedName: "@odata\\.type", - type: { - name: "String" - } - }, - keyId: { required: true, - serializedName: "keyId", + isConstant: true, + serializedName: "@odata\\.type", + defaultValue: '#Microsoft.Azure.Cdn.Models.DeliveryRuleUrlSigningActionParameters', type: { name: "String" } @@ -2222,17 +2233,6 @@ export const UrlSigningActionParameters: msRest.CompositeMapper = { } } } - }, - ipSubnets: { - serializedName: "ipSubnets", - type: { - name: "Sequence", - element: { - type: { - name: "String" - } - } - } } } } @@ -2250,6 +2250,7 @@ export const UrlSigningAction: msRest.CompositeMapper = { parameters: { required: true, serializedName: "parameters", + defaultValue: {}, type: { name: "Composite", className: "UrlSigningActionParameters" @@ -2259,6 +2260,55 @@ export const UrlSigningAction: msRest.CompositeMapper = { } }; +export const OriginGroupOverrideActionParameters: msRest.CompositeMapper = { + serializedName: "OriginGroupOverrideActionParameters", + type: { + name: "Composite", + className: "OriginGroupOverrideActionParameters", + modelProperties: { + odatatype: { + required: true, + isConstant: true, + serializedName: "@odata\\.type", + defaultValue: '#Microsoft.Azure.Cdn.Models.DeliveryRuleOriginGroupOverrideActionParameters', + type: { + name: "String" + } + }, + originGroup: { + required: true, + serializedName: "originGroup", + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + } +}; + +export const OriginGroupOverrideAction: msRest.CompositeMapper = { + serializedName: "OriginGroupOverride", + type: { + name: "Composite", + polymorphicDiscriminator: DeliveryRuleAction.type.polymorphicDiscriminator, + uberParent: "DeliveryRuleAction", + className: "OriginGroupOverrideAction", + modelProperties: { + ...DeliveryRuleAction.type.modelProperties, + parameters: { + required: true, + serializedName: "parameters", + defaultValue: {}, + type: { + name: "Composite", + className: "OriginGroupOverrideActionParameters" + } + } + } + } +}; + export const UrlRewriteActionParameters: msRest.CompositeMapper = { serializedName: "UrlRewriteActionParameters", type: { @@ -2890,6 +2940,46 @@ export const OriginGroupUpdateParameters: msRest.CompositeMapper = { } }; +export const CustomDomainHttpsParameters: msRest.CompositeMapper = { + serializedName: "CustomDomainHttpsParameters", + type: { + name: "Composite", + polymorphicDiscriminator: { + serializedName: "certificateSource", + clientName: "certificateSource" + }, + uberParent: "CustomDomainHttpsParameters", + className: "CustomDomainHttpsParameters", + modelProperties: { + protocolType: { + required: true, + serializedName: "protocolType", + type: { + name: "String" + } + }, + minimumTlsVersion: { + serializedName: "minimumTlsVersion", + type: { + name: "Enum", + allowedValues: [ + "None", + "TLS10", + "TLS12" + ] + } + }, + certificateSource: { + required: true, + serializedName: "certificateSource", + type: { + name: "String" + } + } + } + } +}; + export const CustomDomain: msRest.CompositeMapper = { serializedName: "CustomDomain", type: { @@ -2925,6 +3015,13 @@ export const CustomDomain: msRest.CompositeMapper = { name: "String" } }, + customHttpsParameters: { + serializedName: "properties.customHttpsParameters", + type: { + name: "Composite", + className: "CustomDomainHttpsParameters" + } + }, validationData: { serializedName: "properties.validationData", type: { @@ -2959,46 +3056,6 @@ export const CustomDomainParameters: msRest.CompositeMapper = { } }; -export const CustomDomainHttpsParameters: msRest.CompositeMapper = { - serializedName: "CustomDomainHttpsParameters", - type: { - name: "Composite", - polymorphicDiscriminator: { - serializedName: "certificateSource", - clientName: "certificateSource" - }, - uberParent: "CustomDomainHttpsParameters", - className: "CustomDomainHttpsParameters", - modelProperties: { - protocolType: { - required: true, - serializedName: "protocolType", - type: { - name: "String" - } - }, - minimumTlsVersion: { - serializedName: "minimumTlsVersion", - type: { - name: "Enum", - allowedValues: [ - "None", - "TLS10", - "TLS12" - ] - } - }, - certificateSource: { - required: true, - serializedName: "certificateSource", - type: { - name: "String" - } - } - } - } -}; - export const CdnCertificateSourceParameters: msRest.CompositeMapper = { serializedName: "CdnCertificateSourceParameters", type: { @@ -3472,6 +3529,52 @@ export const EdgeNode: msRest.CompositeMapper = { } }; +export const SystemData: msRest.CompositeMapper = { + serializedName: "SystemData", + type: { + name: "Composite", + className: "SystemData", + modelProperties: { + createdBy: { + serializedName: "createdBy", + type: { + name: "String" + } + }, + createdByType: { + serializedName: "createdByType", + type: { + name: "String" + } + }, + createdAt: { + serializedName: "createdAt", + type: { + name: "DateTime" + } + }, + lastModifiedBy: { + serializedName: "lastModifiedBy", + type: { + name: "String" + } + }, + lastModifiedByType: { + serializedName: "lastModifiedByType", + type: { + name: "String" + } + }, + lastModifiedAt: { + serializedName: "lastModifiedAt", + type: { + name: "DateTime" + } + } + } + } +}; + export const ErrorResponse: msRest.CompositeMapper = { serializedName: "ErrorResponse", type: { @@ -3496,41 +3599,59 @@ export const ErrorResponse: msRest.CompositeMapper = { } }; -export const PolicySettings: msRest.CompositeMapper = { - serializedName: "policySettings", +export const AfdPurgeParameters: msRest.CompositeMapper = { + serializedName: "AfdPurgeParameters", type: { name: "Composite", - className: "PolicySettings", + className: "AfdPurgeParameters", modelProperties: { - enabledState: { - serializedName: "enabledState", + contentPaths: { + required: true, + serializedName: "contentPaths", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } }, - mode: { - serializedName: "mode", + domains: { + serializedName: "domains", type: { - name: "String" + name: "Sequence", + element: { + type: { + name: "String" + } + } } - }, - defaultRedirectUrl: { - serializedName: "defaultRedirectUrl", + } + } + } +}; + +export const Certificate: msRest.CompositeMapper = { + serializedName: "Certificate", + type: { + name: "Composite", + className: "Certificate", + modelProperties: { + subject: { + serializedName: "subject", type: { name: "String" } }, - defaultCustomBlockResponseStatusCode: { - serializedName: "defaultCustomBlockResponseStatusCode", + expirationDate: { + serializedName: "expirationDate", type: { - name: "Number" + name: "String" } }, - defaultCustomBlockResponseBody: { - serializedName: "defaultCustomBlockResponseBody", - constraints: { - Pattern: /^(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=|[A-Za-z0-9+\/]{4})$/ - }, + thumbprint: { + serializedName: "thumbprint", type: { name: "String" } @@ -3539,44 +3660,2310 @@ export const PolicySettings: msRest.CompositeMapper = { } }; -export const CustomRule: msRest.CompositeMapper = { - serializedName: "CustomRule", +export const ManagedCertificate: msRest.CompositeMapper = { + serializedName: "ManagedCertificate", type: { name: "Composite", - className: "CustomRule", + className: "ManagedCertificate", modelProperties: { - name: { - required: true, - serializedName: "name", + ...Certificate.type.modelProperties + } + } +}; + +export const CustomerCertificate: msRest.CompositeMapper = { + serializedName: "CustomerCertificate", + type: { + name: "Composite", + className: "CustomerCertificate", + modelProperties: { + ...Certificate.type.modelProperties, + version: { + serializedName: "version", type: { name: "String" } }, - enabledState: { - serializedName: "enabledState", + certificateAuthority: { + serializedName: "certificateAuthority", type: { name: "String" } }, - priority: { + certificateUrl: { required: true, - serializedName: "priority", - constraints: { - InclusiveMaximum: 1000, - InclusiveMinimum: 0 - }, + serializedName: "certificateUrl", type: { - name: "Number" + name: "String" } }, - matchConditions: { - required: true, - serializedName: "matchConditions", + useLatestVersion: { + serializedName: "useLatestVersion", + type: { + name: "Boolean" + } + }, + subjectAlternativeNames: { + serializedName: "subjectAlternativeNames", type: { name: "Sequence", element: { type: { - name: "Composite", + name: "String" + } + } + } + } + } + } +}; + +export const ValidateSecretInput: msRest.CompositeMapper = { + serializedName: "ValidateSecretInput", + type: { + name: "Composite", + className: "ValidateSecretInput", + modelProperties: { + secretSource: { + required: true, + serializedName: "secretSource", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + secretType: { + required: true, + serializedName: "secretType", + type: { + name: "String" + } + } + } + } +}; + +export const ValidateSecretOutput: msRest.CompositeMapper = { + serializedName: "ValidateSecretOutput", + type: { + name: "Composite", + className: "ValidateSecretOutput", + modelProperties: { + status: { + serializedName: "status", + type: { + name: "String" + } + }, + message: { + serializedName: "message", + type: { + name: "String" + } + } + } + } +}; + +export const AFDDomainHttpsParameters: msRest.CompositeMapper = { + serializedName: "AFDDomainHttpsParameters", + type: { + name: "Composite", + className: "AFDDomainHttpsParameters", + modelProperties: { + certificateType: { + required: true, + serializedName: "certificateType", + type: { + name: "String" + } + }, + minimumTlsVersion: { + serializedName: "minimumTlsVersion", + type: { + name: "Enum", + allowedValues: [ + "TLS10", + "TLS12" + ] + } + }, + secret: { + serializedName: "secret", + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + } +}; + +export const DomainValidationProperties: msRest.CompositeMapper = { + serializedName: "DomainValidationProperties", + type: { + name: "Composite", + className: "DomainValidationProperties", + modelProperties: { + validationToken: { + readOnly: true, + serializedName: "validationToken", + type: { + name: "String" + } + }, + expirationDate: { + readOnly: true, + serializedName: "expirationDate", + type: { + name: "String" + } + } + } + } +}; + +export const AFDDomain: msRest.CompositeMapper = { + serializedName: "AFDDomain", + type: { + name: "Composite", + className: "AFDDomain", + modelProperties: { + ...ProxyResource.type.modelProperties, + tlsSettings: { + serializedName: "properties.tlsSettings", + type: { + name: "Composite", + className: "AFDDomainHttpsParameters" + } + }, + azureDnsZone: { + serializedName: "properties.azureDnsZone", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + }, + domainValidationState: { + readOnly: true, + serializedName: "properties.domainValidationState", + type: { + name: "String" + } + }, + hostName: { + required: true, + serializedName: "properties.hostName", + type: { + name: "String" + } + }, + validationProperties: { + readOnly: true, + serializedName: "properties.validationProperties", + type: { + name: "Composite", + className: "DomainValidationProperties" + } + } + } + } +}; + +export const AFDDomainUpdateParameters: msRest.CompositeMapper = { + serializedName: "AFDDomainUpdateParameters", + type: { + name: "Composite", + className: "AFDDomainUpdateParameters", + modelProperties: { + tlsSettings: { + serializedName: "properties.tlsSettings", + type: { + name: "Composite", + className: "AFDDomainHttpsParameters" + } + }, + azureDnsZone: { + serializedName: "properties.azureDnsZone", + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + } +}; + +export const SecurityPolicyParameters: msRest.CompositeMapper = { + serializedName: "SecurityPolicyParameters", + type: { + name: "Composite", + polymorphicDiscriminator: { + serializedName: "type", + clientName: "type" + }, + uberParent: "SecurityPolicyParameters", + className: "SecurityPolicyParameters", + modelProperties: { + type: { + required: true, + serializedName: "type", + type: { + name: "String" + } + } + } + } +}; + +export const AFDStateProperties: msRest.CompositeMapper = { + serializedName: "AFDStateProperties", + type: { + name: "Composite", + className: "AFDStateProperties", + modelProperties: { + provisioningState: { + readOnly: true, + serializedName: "provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "deploymentStatus", + type: { + name: "String" + } + } + } + } +}; + +export const SecurityPolicyProperties: msRest.CompositeMapper = { + serializedName: "SecurityPolicyProperties", + type: { + name: "Composite", + className: "SecurityPolicyProperties", + modelProperties: { + ...AFDStateProperties.type.modelProperties, + parameters: { + serializedName: "parameters", + type: { + name: "Composite", + className: "SecurityPolicyParameters" + } + } + } + } +}; + +export const SecurityPolicy: msRest.CompositeMapper = { + serializedName: "SecurityPolicy", + type: { + name: "Composite", + className: "SecurityPolicy", + modelProperties: { + ...ProxyResource.type.modelProperties, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + }, + parameters: { + serializedName: "properties.parameters", + type: { + name: "Composite", + className: "SecurityPolicyParameters" + } + } + } + } +}; + +export const SecurityPolicyWebApplicationFirewallAssociation: msRest.CompositeMapper = { + serializedName: "SecurityPolicyWebApplicationFirewallAssociation", + type: { + name: "Composite", + className: "SecurityPolicyWebApplicationFirewallAssociation", + modelProperties: { + domains: { + serializedName: "domains", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + }, + patternsToMatch: { + serializedName: "patternsToMatch", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const SecurityPolicyWebApplicationFirewallParameters: msRest.CompositeMapper = { + serializedName: "WebApplicationFirewall", + type: { + name: "Composite", + polymorphicDiscriminator: SecurityPolicyParameters.type.polymorphicDiscriminator, + uberParent: "SecurityPolicyParameters", + className: "SecurityPolicyWebApplicationFirewallParameters", + modelProperties: { + ...SecurityPolicyParameters.type.modelProperties, + wafPolicy: { + serializedName: "wafPolicy", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + associations: { + serializedName: "associations", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SecurityPolicyWebApplicationFirewallAssociation" + } + } + } + } + } + } +}; + +export const AFDEndpoint: msRest.CompositeMapper = { + serializedName: "AFDEndpoint", + type: { + name: "Composite", + className: "AFDEndpoint", + modelProperties: { + ...TrackedResource.type.modelProperties, + originResponseTimeoutSeconds: { + serializedName: "properties.originResponseTimeoutSeconds", + constraints: { + InclusiveMinimum: 16 + }, + type: { + name: "Number" + } + }, + enabledState: { + serializedName: "properties.enabledState", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + }, + hostName: { + readOnly: true, + serializedName: "properties.hostName", + type: { + name: "String" + } + } + } + } +}; + +export const AFDEndpointUpdateParameters: msRest.CompositeMapper = { + serializedName: "AFDEndpointUpdateParameters", + type: { + name: "Composite", + className: "AFDEndpointUpdateParameters", + modelProperties: { + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + originResponseTimeoutSeconds: { + serializedName: "properties.originResponseTimeoutSeconds", + constraints: { + InclusiveMinimum: 16 + }, + type: { + name: "Number" + } + }, + enabledState: { + serializedName: "properties.enabledState", + type: { + name: "String" + } + } + } + } +}; + +export const CompressionSettings: msRest.CompositeMapper = { + serializedName: "CompressionSettings", + type: { + name: "Composite", + className: "CompressionSettings", + modelProperties: { + contentTypesToCompress: { + serializedName: "contentTypesToCompress", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + isCompressionEnabled: { + serializedName: "isCompressionEnabled", + type: { + name: "Boolean" + } + } + } + } +}; + +export const SecretParameters: msRest.CompositeMapper = { + serializedName: "SecretParameters", + type: { + name: "Composite", + polymorphicDiscriminator: { + serializedName: "type", + clientName: "type" + }, + uberParent: "SecretParameters", + className: "SecretParameters", + modelProperties: { + type: { + required: true, + serializedName: "type", + type: { + name: "String" + } + } + } + } +}; + +export const SecretProperties: msRest.CompositeMapper = { + serializedName: "SecretProperties", + type: { + name: "Composite", + className: "SecretProperties", + modelProperties: { + ...AFDStateProperties.type.modelProperties, + parameters: { + serializedName: "parameters", + type: { + name: "Composite", + className: "SecretParameters" + } + } + } + } +}; + +export const Secret: msRest.CompositeMapper = { + serializedName: "Secret", + type: { + name: "Composite", + className: "Secret", + modelProperties: { + ...ProxyResource.type.modelProperties, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + }, + parameters: { + serializedName: "properties.parameters", + type: { + name: "Composite", + className: "SecretParameters" + } + } + } + } +}; + +export const UrlSigningKeyParameters: msRest.CompositeMapper = { + serializedName: "UrlSigningKey", + type: { + name: "Composite", + polymorphicDiscriminator: SecretParameters.type.polymorphicDiscriminator, + uberParent: "SecretParameters", + className: "UrlSigningKeyParameters", + modelProperties: { + ...SecretParameters.type.modelProperties, + keyId: { + required: true, + serializedName: "keyId", + type: { + name: "String" + } + }, + secretSource: { + required: true, + serializedName: "secretSource", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + secretVersion: { + serializedName: "secretVersion", + type: { + name: "String" + } + } + } + } +}; + +export const ManagedCertificateParameters: msRest.CompositeMapper = { + serializedName: "ManagedCertificate", + type: { + name: "Composite", + polymorphicDiscriminator: SecretParameters.type.polymorphicDiscriminator, + uberParent: "SecretParameters", + className: "ManagedCertificateParameters", + modelProperties: { + ...SecretParameters.type.modelProperties + } + } +}; + +export const CustomerCertificateParameters: msRest.CompositeMapper = { + serializedName: "CustomerCertificate", + type: { + name: "Composite", + polymorphicDiscriminator: SecretParameters.type.polymorphicDiscriminator, + uberParent: "SecretParameters", + className: "CustomerCertificateParameters", + modelProperties: { + ...SecretParameters.type.modelProperties, + secretSource: { + required: true, + serializedName: "secretSource", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + secretVersion: { + serializedName: "secretVersion", + type: { + name: "String" + } + }, + certificateAuthority: { + serializedName: "certificateAuthority", + type: { + name: "String" + } + }, + useLatestVersion: { + serializedName: "useLatestVersion", + type: { + name: "Boolean" + } + }, + subjectAlternativeNames: { + serializedName: "subjectAlternativeNames", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const RuleSet: msRest.CompositeMapper = { + serializedName: "RuleSet", + type: { + name: "Composite", + className: "RuleSet", + modelProperties: { + ...ProxyResource.type.modelProperties, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + } + } + } +}; + +export const AFDOrigin: msRest.CompositeMapper = { + serializedName: "AFDOrigin", + type: { + name: "Composite", + className: "AFDOrigin", + modelProperties: { + ...ProxyResource.type.modelProperties, + azureOrigin: { + serializedName: "properties.azureOrigin", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + hostName: { + required: true, + serializedName: "properties.hostName", + type: { + name: "String" + } + }, + httpPort: { + serializedName: "properties.httpPort", + constraints: { + InclusiveMaximum: 65535, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + httpsPort: { + serializedName: "properties.httpsPort", + constraints: { + InclusiveMaximum: 65535, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + originHostHeader: { + serializedName: "properties.originHostHeader", + type: { + name: "String" + } + }, + priority: { + serializedName: "properties.priority", + constraints: { + InclusiveMaximum: 5, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + weight: { + serializedName: "properties.weight", + constraints: { + InclusiveMaximum: 1000, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + sharedPrivateLinkResource: { + serializedName: "properties.sharedPrivateLinkResource", + type: { + name: "Object" + } + }, + enabledState: { + serializedName: "properties.enabledState", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + } + } + } +}; + +export const AFDOriginUpdateParameters: msRest.CompositeMapper = { + serializedName: "AFDOriginUpdateParameters", + type: { + name: "Composite", + className: "AFDOriginUpdateParameters", + modelProperties: { + azureOrigin: { + serializedName: "properties.azureOrigin", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + hostName: { + serializedName: "properties.hostName", + type: { + name: "String" + } + }, + httpPort: { + serializedName: "properties.httpPort", + constraints: { + InclusiveMaximum: 65535, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + httpsPort: { + serializedName: "properties.httpsPort", + constraints: { + InclusiveMaximum: 65535, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + originHostHeader: { + serializedName: "properties.originHostHeader", + type: { + name: "String" + } + }, + priority: { + serializedName: "properties.priority", + constraints: { + InclusiveMaximum: 5, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + weight: { + serializedName: "properties.weight", + constraints: { + InclusiveMaximum: 1000, + InclusiveMinimum: 1 + }, + type: { + name: "Number" + } + }, + sharedPrivateLinkResource: { + serializedName: "properties.sharedPrivateLinkResource", + type: { + name: "Object" + } + }, + enabledState: { + serializedName: "properties.enabledState", + type: { + name: "String" + } + } + } + } +}; + +export const SharedPrivateLinkResourceProperties: msRest.CompositeMapper = { + serializedName: "SharedPrivateLinkResourceProperties", + type: { + name: "Composite", + className: "SharedPrivateLinkResourceProperties", + modelProperties: { + privateLink: { + serializedName: "privateLink", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + privateLinkLocation: { + serializedName: "privateLinkLocation", + type: { + name: "String" + } + }, + groupId: { + serializedName: "groupId", + type: { + name: "String" + } + }, + requestMessage: { + serializedName: "requestMessage", + type: { + name: "String" + } + }, + status: { + serializedName: "status", + type: { + name: "Enum", + allowedValues: [ + "Pending", + "Approved", + "Rejected", + "Disconnected", + "Timeout" + ] + } + } + } + } +}; + +export const LoadBalancingSettingsParameters: msRest.CompositeMapper = { + serializedName: "LoadBalancingSettingsParameters", + type: { + name: "Composite", + className: "LoadBalancingSettingsParameters", + modelProperties: { + sampleSize: { + serializedName: "sampleSize", + type: { + name: "Number" + } + }, + successfulSamplesRequired: { + serializedName: "successfulSamplesRequired", + type: { + name: "Number" + } + }, + additionalLatencyInMilliseconds: { + serializedName: "additionalLatencyInMilliseconds", + type: { + name: "Number" + } + } + } + } +}; + +export const AFDOriginGroup: msRest.CompositeMapper = { + serializedName: "AFDOriginGroup", + type: { + name: "Composite", + className: "AFDOriginGroup", + modelProperties: { + ...ProxyResource.type.modelProperties, + loadBalancingSettings: { + serializedName: "properties.loadBalancingSettings", + type: { + name: "Composite", + className: "LoadBalancingSettingsParameters" + } + }, + healthProbeSettings: { + serializedName: "properties.healthProbeSettings", + type: { + name: "Composite", + className: "HealthProbeParameters" + } + }, + trafficRestorationTimeToHealedOrNewEndpointsInMinutes: { + serializedName: "properties.trafficRestorationTimeToHealedOrNewEndpointsInMinutes", + constraints: { + InclusiveMaximum: 50, + InclusiveMinimum: 0 + }, + type: { + name: "Number" + } + }, + responseBasedAfdOriginErrorDetectionSettings: { + serializedName: "properties.responseBasedAfdOriginErrorDetectionSettings", + type: { + name: "Composite", + className: "ResponseBasedOriginErrorDetectionParameters" + } + }, + sessionAffinityState: { + serializedName: "properties.sessionAffinityState", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + } + } + } +}; + +export const AFDOriginGroupUpdateParameters: msRest.CompositeMapper = { + serializedName: "AFDOriginGroupUpdateParameters", + type: { + name: "Composite", + className: "AFDOriginGroupUpdateParameters", + modelProperties: { + loadBalancingSettings: { + serializedName: "properties.loadBalancingSettings", + type: { + name: "Composite", + className: "LoadBalancingSettingsParameters" + } + }, + healthProbeSettings: { + serializedName: "properties.healthProbeSettings", + type: { + name: "Composite", + className: "HealthProbeParameters" + } + }, + trafficRestorationTimeToHealedOrNewEndpointsInMinutes: { + serializedName: "properties.trafficRestorationTimeToHealedOrNewEndpointsInMinutes", + constraints: { + InclusiveMaximum: 50, + InclusiveMinimum: 0 + }, + type: { + name: "Number" + } + }, + responseBasedAfdOriginErrorDetectionSettings: { + serializedName: "properties.responseBasedAfdOriginErrorDetectionSettings", + type: { + name: "Composite", + className: "ResponseBasedOriginErrorDetectionParameters" + } + }, + sessionAffinityState: { + serializedName: "properties.sessionAffinityState", + type: { + name: "String" + } + } + } + } +}; + +export const Route: msRest.CompositeMapper = { + serializedName: "Route", + type: { + name: "Composite", + className: "Route", + modelProperties: { + ...ProxyResource.type.modelProperties, + customDomains: { + serializedName: "properties.customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + }, + originGroup: { + required: true, + serializedName: "properties.originGroup", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + originPath: { + serializedName: "properties.originPath", + type: { + name: "String" + } + }, + ruleSets: { + serializedName: "properties.ruleSets", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + }, + supportedProtocols: { + serializedName: "properties.supportedProtocols", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + patternsToMatch: { + serializedName: "properties.patternsToMatch", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + compressionSettings: { + serializedName: "properties.compressionSettings", + type: { + name: "Object" + } + }, + queryStringCachingBehavior: { + serializedName: "properties.queryStringCachingBehavior", + type: { + name: "Enum", + allowedValues: [ + "IgnoreQueryString", + "UseQueryString", + "NotSet" + ] + } + }, + forwardingProtocol: { + serializedName: "properties.forwardingProtocol", + type: { + name: "String" + } + }, + linkToDefaultDomain: { + serializedName: "properties.linkToDefaultDomain", + type: { + name: "String" + } + }, + httpsRedirect: { + serializedName: "properties.httpsRedirect", + type: { + name: "String" + } + }, + enabledState: { + serializedName: "properties.enabledState", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + } + } + } +}; + +export const RouteUpdateParameters: msRest.CompositeMapper = { + serializedName: "RouteUpdateParameters", + type: { + name: "Composite", + className: "RouteUpdateParameters", + modelProperties: { + customDomains: { + serializedName: "properties.customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + }, + originGroup: { + serializedName: "properties.originGroup", + type: { + name: "Composite", + className: "ResourceReference" + } + }, + originPath: { + serializedName: "properties.originPath", + type: { + name: "String" + } + }, + ruleSets: { + serializedName: "properties.ruleSets", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceReference" + } + } + } + }, + supportedProtocols: { + serializedName: "properties.supportedProtocols", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + patternsToMatch: { + serializedName: "properties.patternsToMatch", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + compressionSettings: { + serializedName: "properties.compressionSettings", + type: { + name: "Object" + } + }, + queryStringCachingBehavior: { + serializedName: "properties.queryStringCachingBehavior", + type: { + name: "Enum", + allowedValues: [ + "IgnoreQueryString", + "UseQueryString", + "NotSet" + ] + } + }, + forwardingProtocol: { + serializedName: "properties.forwardingProtocol", + type: { + name: "String" + } + }, + linkToDefaultDomain: { + serializedName: "properties.linkToDefaultDomain", + type: { + name: "String" + } + }, + httpsRedirect: { + serializedName: "properties.httpsRedirect", + type: { + name: "String" + } + }, + enabledState: { + serializedName: "properties.enabledState", + type: { + name: "String" + } + } + } + } +}; + +export const Rule: msRest.CompositeMapper = { + serializedName: "Rule", + type: { + name: "Composite", + className: "Rule", + modelProperties: { + ...ProxyResource.type.modelProperties, + order: { + required: true, + serializedName: "properties.order", + type: { + name: "Number" + } + }, + conditions: { + serializedName: "properties.conditions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DeliveryRuleCondition" + } + } + } + }, + actions: { + required: true, + serializedName: "properties.actions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DeliveryRuleAction" + } + } + } + }, + matchProcessingBehavior: { + serializedName: "properties.matchProcessingBehavior", + type: { + name: "String" + } + }, + provisioningState: { + readOnly: true, + serializedName: "properties.provisioningState", + type: { + name: "String" + } + }, + deploymentStatus: { + readOnly: true, + serializedName: "properties.deploymentStatus", + type: { + name: "String" + } + } + } + } +}; + +export const RuleUpdateParameters: msRest.CompositeMapper = { + serializedName: "RuleUpdateParameters", + type: { + name: "Composite", + className: "RuleUpdateParameters", + modelProperties: { + order: { + serializedName: "properties.order", + type: { + name: "Number" + } + }, + conditions: { + serializedName: "properties.conditions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DeliveryRuleCondition" + } + } + } + }, + actions: { + serializedName: "properties.actions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DeliveryRuleAction" + } + } + } + }, + matchProcessingBehavior: { + serializedName: "properties.matchProcessingBehavior", + type: { + name: "String" + } + } + } + } +}; + +export const ValidationToken: msRest.CompositeMapper = { + serializedName: "ValidationToken", + type: { + name: "Composite", + className: "ValidationToken", + modelProperties: { + token: { + readOnly: true, + serializedName: "token", + type: { + name: "String" + } + } + } + } +}; + +export const AfdErrorResponse: msRest.CompositeMapper = { + serializedName: "AfdErrorResponse", + type: { + name: "Composite", + className: "AfdErrorResponse", + modelProperties: { + error: { + serializedName: "error", + type: { + name: "Composite", + className: "ErrorResponse" + } + } + } + } +}; + +export const MetricsResponseSeriesItemGroupsItem: msRest.CompositeMapper = { + serializedName: "MetricsResponse_seriesItem_groupsItem", + type: { + name: "Composite", + className: "MetricsResponseSeriesItemGroupsItem", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + value: { + serializedName: "value", + type: { + name: "String" + } + } + } + } +}; + +export const MetricsResponseSeriesItemDataItem: msRest.CompositeMapper = { + serializedName: "MetricsResponse_seriesItem_dataItem", + type: { + name: "Composite", + className: "MetricsResponseSeriesItemDataItem", + modelProperties: { + dateTime: { + serializedName: "dateTime", + type: { + name: "DateTime" + } + }, + value: { + serializedName: "value", + type: { + name: "Number" + } + } + } + } +}; + +export const MetricsResponseSeriesItem: msRest.CompositeMapper = { + serializedName: "MetricsResponse_seriesItem", + type: { + name: "Composite", + className: "MetricsResponseSeriesItem", + modelProperties: { + metric: { + serializedName: "metric", + type: { + name: "String" + } + }, + unit: { + serializedName: "unit", + type: { + name: "String" + } + }, + groups: { + serializedName: "groups", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MetricsResponseSeriesItemGroupsItem" + } + } + } + }, + data: { + serializedName: "data", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MetricsResponseSeriesItemDataItem" + } + } + } + } + } + } +}; + +export const MetricsResponse: msRest.CompositeMapper = { + serializedName: "MetricsResponse", + type: { + name: "Composite", + className: "MetricsResponse", + modelProperties: { + dateTimeBegin: { + serializedName: "dateTimeBegin", + type: { + name: "DateTime" + } + }, + dateTimeEnd: { + serializedName: "dateTimeEnd", + type: { + name: "DateTime" + } + }, + granularity: { + serializedName: "granularity", + type: { + name: "String" + } + }, + series: { + serializedName: "series", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MetricsResponseSeriesItem" + } + } + } + } + } + } +}; + +export const RankingsResponseTablesItemDataItemMetricsItem: msRest.CompositeMapper = { + serializedName: "RankingsResponse_tablesItem_dataItem_metricsItem", + type: { + name: "Composite", + className: "RankingsResponseTablesItemDataItemMetricsItem", + modelProperties: { + metric: { + serializedName: "metric", + type: { + name: "String" + } + }, + value: { + serializedName: "value", + type: { + name: "Number" + } + }, + percentage: { + serializedName: "percentage", + type: { + name: "Number" + } + } + } + } +}; + +export const RankingsResponseTablesItemDataItem: msRest.CompositeMapper = { + serializedName: "RankingsResponse_tablesItem_dataItem", + type: { + name: "Composite", + className: "RankingsResponseTablesItemDataItem", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + metrics: { + serializedName: "metrics", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "RankingsResponseTablesItemDataItemMetricsItem" + } + } + } + } + } + } +}; + +export const RankingsResponseTablesItem: msRest.CompositeMapper = { + serializedName: "RankingsResponse_tablesItem", + type: { + name: "Composite", + className: "RankingsResponseTablesItem", + modelProperties: { + ranking: { + serializedName: "ranking", + type: { + name: "String" + } + }, + data: { + serializedName: "data", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "RankingsResponseTablesItemDataItem" + } + } + } + } + } + } +}; + +export const RankingsResponse: msRest.CompositeMapper = { + serializedName: "RankingsResponse", + type: { + name: "Composite", + className: "RankingsResponse", + modelProperties: { + dateTimeBegin: { + serializedName: "dateTimeBegin", + type: { + name: "DateTime" + } + }, + dateTimeEnd: { + serializedName: "dateTimeEnd", + type: { + name: "DateTime" + } + }, + tables: { + serializedName: "tables", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "RankingsResponseTablesItem" + } + } + } + } + } + } +}; + +export const ContinentsResponseContinentsItem: msRest.CompositeMapper = { + serializedName: "ContinentsResponse_continentsItem", + type: { + name: "Composite", + className: "ContinentsResponseContinentsItem", + modelProperties: { + id: { + serializedName: "id", + type: { + name: "String" + } + } + } + } +}; + +export const ContinentsResponseCountryOrRegionsItem: msRest.CompositeMapper = { + serializedName: "ContinentsResponse_countryOrRegionsItem", + type: { + name: "Composite", + className: "ContinentsResponseCountryOrRegionsItem", + modelProperties: { + id: { + serializedName: "id", + type: { + name: "String" + } + }, + continentId: { + serializedName: "continentId", + type: { + name: "String" + } + } + } + } +}; + +export const ContinentsResponse: msRest.CompositeMapper = { + serializedName: "ContinentsResponse", + type: { + name: "Composite", + className: "ContinentsResponse", + modelProperties: { + continents: { + serializedName: "continents", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ContinentsResponseContinentsItem" + } + } + } + }, + countryOrRegions: { + serializedName: "countryOrRegions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ContinentsResponseCountryOrRegionsItem" + } + } + } + } + } + } +}; + +export const ResourcesResponseEndpointsItemCustomDomainsItem: msRest.CompositeMapper = { + serializedName: "ResourcesResponse_endpointsItem_customDomainsItem", + type: { + name: "Composite", + className: "ResourcesResponseEndpointsItemCustomDomainsItem", + modelProperties: { + id: { + serializedName: "id", + type: { + name: "String" + } + }, + name: { + serializedName: "name", + type: { + name: "String" + } + }, + endpointId: { + serializedName: "endpointId", + type: { + name: "String" + } + }, + history: { + serializedName: "history", + type: { + name: "Boolean" + } + } + } + } +}; + +export const ResourcesResponseEndpointsItem: msRest.CompositeMapper = { + serializedName: "ResourcesResponse_endpointsItem", + type: { + name: "Composite", + className: "ResourcesResponseEndpointsItem", + modelProperties: { + id: { + serializedName: "id", + type: { + name: "String" + } + }, + name: { + serializedName: "name", + type: { + name: "String" + } + }, + history: { + serializedName: "history", + type: { + name: "Boolean" + } + }, + customDomains: { + serializedName: "customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourcesResponseEndpointsItemCustomDomainsItem" + } + } + } + } + } + } +}; + +export const ResourcesResponseCustomDomainsItem: msRest.CompositeMapper = { + serializedName: "ResourcesResponse_customDomainsItem", + type: { + name: "Composite", + className: "ResourcesResponseCustomDomainsItem", + modelProperties: { + id: { + serializedName: "id", + type: { + name: "String" + } + }, + name: { + serializedName: "name", + type: { + name: "String" + } + }, + endpointId: { + serializedName: "endpointId", + type: { + name: "String" + } + }, + history: { + serializedName: "history", + type: { + name: "Boolean" + } + } + } + } +}; + +export const ResourcesResponse: msRest.CompositeMapper = { + serializedName: "ResourcesResponse", + type: { + name: "Composite", + className: "ResourcesResponse", + modelProperties: { + endpoints: { + serializedName: "endpoints", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourcesResponseEndpointsItem" + } + } + } + }, + customDomains: { + serializedName: "customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourcesResponseCustomDomainsItem" + } + } + } + } + } + } +}; + +export const WafMetricsResponseSeriesItemGroupsItem: msRest.CompositeMapper = { + serializedName: "WafMetricsResponse_seriesItem_groupsItem", + type: { + name: "Composite", + className: "WafMetricsResponseSeriesItemGroupsItem", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + value: { + serializedName: "value", + type: { + name: "String" + } + } + } + } +}; + +export const WafMetricsResponseSeriesItemDataItem: msRest.CompositeMapper = { + serializedName: "WafMetricsResponse_seriesItem_dataItem", + type: { + name: "Composite", + className: "WafMetricsResponseSeriesItemDataItem", + modelProperties: { + dateTime: { + serializedName: "dateTime", + type: { + name: "DateTime" + } + }, + value: { + serializedName: "value", + type: { + name: "Number" + } + } + } + } +}; + +export const WafMetricsResponseSeriesItem: msRest.CompositeMapper = { + serializedName: "WafMetricsResponse_seriesItem", + type: { + name: "Composite", + className: "WafMetricsResponseSeriesItem", + modelProperties: { + metric: { + serializedName: "metric", + type: { + name: "String" + } + }, + unit: { + serializedName: "unit", + type: { + name: "String" + } + }, + groups: { + serializedName: "groups", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WafMetricsResponseSeriesItemGroupsItem" + } + } + } + }, + data: { + serializedName: "data", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WafMetricsResponseSeriesItemDataItem" + } + } + } + } + } + } +}; + +export const WafMetricsResponse: msRest.CompositeMapper = { + serializedName: "WafMetricsResponse", + type: { + name: "Composite", + className: "WafMetricsResponse", + modelProperties: { + dateTimeBegin: { + serializedName: "dateTimeBegin", + type: { + name: "DateTime" + } + }, + dateTimeEnd: { + serializedName: "dateTimeEnd", + type: { + name: "DateTime" + } + }, + granularity: { + serializedName: "granularity", + type: { + name: "String" + } + }, + series: { + serializedName: "series", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WafMetricsResponseSeriesItem" + } + } + } + } + } + } +}; + +export const WafRankingsResponseDataItemMetricsItem: msRest.CompositeMapper = { + serializedName: "WafRankingsResponse_dataItem_metricsItem", + type: { + name: "Composite", + className: "WafRankingsResponseDataItemMetricsItem", + modelProperties: { + metric: { + serializedName: "metric", + type: { + name: "String" + } + }, + value: { + serializedName: "value", + type: { + name: "Number" + } + }, + percentage: { + serializedName: "percentage", + type: { + name: "Number" + } + } + } + } +}; + +export const WafRankingsResponseDataItem: msRest.CompositeMapper = { + serializedName: "WafRankingsResponse_dataItem", + type: { + name: "Composite", + className: "WafRankingsResponseDataItem", + modelProperties: { + groupValues: { + serializedName: "groupValues", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + metrics: { + serializedName: "metrics", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WafRankingsResponseDataItemMetricsItem" + } + } + } + } + } + } +}; + +export const WafRankingsResponse: msRest.CompositeMapper = { + serializedName: "WafRankingsResponse", + type: { + name: "Composite", + className: "WafRankingsResponse", + modelProperties: { + dateTimeBegin: { + serializedName: "dateTimeBegin", + type: { + name: "DateTime" + } + }, + dateTimeEnd: { + serializedName: "dateTimeEnd", + type: { + name: "DateTime" + } + }, + groups: { + serializedName: "groups", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + data: { + serializedName: "data", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "WafRankingsResponseDataItem" + } + } + } + } + } + } +}; + +export const UsageName: msRest.CompositeMapper = { + serializedName: "UsageName", + type: { + name: "Composite", + className: "UsageName", + modelProperties: { + value: { + serializedName: "value", + type: { + name: "String" + } + }, + localizedValue: { + serializedName: "localizedValue", + type: { + name: "String" + } + } + } + } +}; + +export const Usage: msRest.CompositeMapper = { + serializedName: "Usage", + type: { + name: "Composite", + className: "Usage", + modelProperties: { + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + unit: { + required: true, + isConstant: true, + serializedName: "unit", + defaultValue: 'Count', + type: { + name: "String" + } + }, + currentValue: { + required: true, + serializedName: "currentValue", + type: { + name: "Number" + } + }, + limit: { + required: true, + serializedName: "limit", + type: { + name: "Number" + } + }, + name: { + required: true, + serializedName: "name", + type: { + name: "Composite", + className: "UsageName" + } + } + } + } +}; + +export const PolicySettings: msRest.CompositeMapper = { + serializedName: "policySettings", + type: { + name: "Composite", + className: "PolicySettings", + modelProperties: { + enabledState: { + serializedName: "enabledState", + type: { + name: "String" + } + }, + mode: { + serializedName: "mode", + type: { + name: "String" + } + }, + defaultRedirectUrl: { + serializedName: "defaultRedirectUrl", + type: { + name: "String" + } + }, + defaultCustomBlockResponseStatusCode: { + serializedName: "defaultCustomBlockResponseStatusCode", + type: { + name: "Number" + } + }, + defaultCustomBlockResponseBody: { + serializedName: "defaultCustomBlockResponseBody", + constraints: { + Pattern: /^(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=|[A-Za-z0-9+\/]{4})$/ + }, + type: { + name: "String" + } + } + } + } +}; + +export const CustomRule: msRest.CompositeMapper = { + serializedName: "CustomRule", + type: { + name: "Composite", + className: "CustomRule", + modelProperties: { + name: { + required: true, + serializedName: "name", + type: { + name: "String" + } + }, + enabledState: { + serializedName: "enabledState", + type: { + name: "String" + } + }, + priority: { + required: true, + serializedName: "priority", + constraints: { + InclusiveMaximum: 1000, + InclusiveMinimum: 0 + }, + type: { + name: "Number" + } + }, + matchConditions: { + required: true, + serializedName: "matchConditions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", className: "MatchCondition" } } @@ -4316,6 +6703,295 @@ export const EdgenodeResult: msRest.CompositeMapper = { } }; +export const UsagesListResult: msRest.CompositeMapper = { + serializedName: "UsagesListResult", + type: { + name: "Composite", + className: "UsagesListResult", + modelProperties: { + value: { + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Usage" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const AFDDomainListResult: msRest.CompositeMapper = { + serializedName: "AFDDomainListResult", + type: { + name: "Composite", + className: "AFDDomainListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "AFDDomain" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const AFDEndpointListResult: msRest.CompositeMapper = { + serializedName: "AFDEndpointListResult", + type: { + name: "Composite", + className: "AFDEndpointListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "AFDEndpoint" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const AFDOriginGroupListResult: msRest.CompositeMapper = { + serializedName: "AFDOriginGroupListResult", + type: { + name: "Composite", + className: "AFDOriginGroupListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "AFDOriginGroup" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const AFDOriginListResult: msRest.CompositeMapper = { + serializedName: "AFDOriginListResult", + type: { + name: "Composite", + className: "AFDOriginListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "AFDOrigin" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const RouteListResult: msRest.CompositeMapper = { + serializedName: "RouteListResult", + type: { + name: "Composite", + className: "RouteListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Route" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const RuleSetListResult: msRest.CompositeMapper = { + serializedName: "RuleSetListResult", + type: { + name: "Composite", + className: "RuleSetListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "RuleSet" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const RuleListResult: msRest.CompositeMapper = { + serializedName: "RuleListResult", + type: { + name: "Composite", + className: "RuleListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Rule" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const SecurityPolicyListResult: msRest.CompositeMapper = { + serializedName: "SecurityPolicyListResult", + type: { + name: "Composite", + className: "SecurityPolicyListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SecurityPolicy" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const SecretListResult: msRest.CompositeMapper = { + serializedName: "SecretListResult", + type: { + name: "Composite", + className: "SecretListResult", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Secret" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + export const CdnWebApplicationFirewallPolicyList: msRest.CompositeMapper = { serializedName: "CdnWebApplicationFirewallPolicyList", type: { @@ -4393,6 +7069,7 @@ export const discriminators = { 'DeliveryRuleCondition.IsDevice' : DeliveryRuleIsDeviceCondition, 'DeliveryRuleAction.UrlRedirect' : UrlRedirectAction, 'DeliveryRuleAction.UrlSigning' : UrlSigningAction, + 'DeliveryRuleAction.OriginGroupOverride' : OriginGroupOverrideAction, 'DeliveryRuleAction.UrlRewrite' : UrlRewriteAction, 'DeliveryRuleAction.ModifyRequestHeader' : DeliveryRuleRequestHeaderAction, 'DeliveryRuleAction.ModifyResponseHeader' : DeliveryRuleResponseHeaderAction, @@ -4400,6 +7077,12 @@ export const discriminators = { 'DeliveryRuleAction.CacheKeyQueryString' : DeliveryRuleCacheKeyQueryStringAction, 'CustomDomainHttpsParameters' : CustomDomainHttpsParameters, 'CustomDomainHttpsParameters.Cdn' : CdnManagedHttpsParameters, - 'CustomDomainHttpsParameters.AzureKeyVault' : UserManagedHttpsParameters + 'CustomDomainHttpsParameters.AzureKeyVault' : UserManagedHttpsParameters, + 'SecurityPolicyParameters' : SecurityPolicyParameters, + 'SecurityPolicyParameters.WebApplicationFirewall' : SecurityPolicyWebApplicationFirewallParameters, + 'SecretParameters' : SecretParameters, + 'SecretParameters.UrlSigningKey' : UrlSigningKeyParameters, + 'SecretParameters.ManagedCertificate' : ManagedCertificateParameters, + 'SecretParameters.CustomerCertificate' : CustomerCertificateParameters }; diff --git a/sdk/cdn/arm-cdn/src/models/operationsMappers.ts b/sdk/cdn/arm-cdn/src/models/operationsMappers.ts index b4fe02631a85..29759ce77166 100644 --- a/sdk/cdn/arm-cdn/src/models/operationsMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/operationsMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. diff --git a/sdk/cdn/arm-cdn/src/models/originGroupsMappers.ts b/sdk/cdn/arm-cdn/src/models/originGroupsMappers.ts index d249da8af3d5..cfbd0cf83706 100644 --- a/sdk/cdn/arm-cdn/src/models/originGroupsMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/originGroupsMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,15 +8,27 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, CdnEndpoint, + CdnManagedHttpsParameters, CdnWebApplicationFirewallPolicy, CdnWebApplicationFirewallPolicyPatchParameters, CidrIpAddress, CookiesMatchConditionParameters, CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -42,6 +54,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, Endpoint, EndpointPropertiesUpdateParametersDeliveryPolicy, @@ -55,7 +68,10 @@ export { HttpVersionMatchConditionParameters, IpAddressGroup, IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -67,6 +83,8 @@ export { Origin, OriginGroup, OriginGroupListResult, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginUpdateParameters, PolicySettings, @@ -86,7 +104,17 @@ export { Resource, ResourceReference, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -98,5 +126,7 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, - UrlSigningParamIdentifier + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/originsMappers.ts b/sdk/cdn/arm-cdn/src/models/originsMappers.ts index ac713095f07d..4d181646dfbd 100644 --- a/sdk/cdn/arm-cdn/src/models/originsMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/originsMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,15 +8,27 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, CdnEndpoint, + CdnManagedHttpsParameters, CdnWebApplicationFirewallPolicy, CdnWebApplicationFirewallPolicyPatchParameters, CidrIpAddress, CookiesMatchConditionParameters, CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -42,6 +54,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, Endpoint, EndpointPropertiesUpdateParametersDeliveryPolicy, @@ -55,7 +68,10 @@ export { HttpVersionMatchConditionParameters, IpAddressGroup, IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -66,6 +82,8 @@ export { MatchCondition, Origin, OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginListResult, OriginUpdateParameters, @@ -86,7 +104,17 @@ export { Resource, ResourceReference, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -98,5 +126,7 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, - UrlSigningParamIdentifier + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/parameters.ts b/sdk/cdn/arm-cdn/src/models/parameters.ts index 783ef8f1bc84..23cc57bb6807 100644 --- a/sdk/cdn/arm-cdn/src/models/parameters.ts +++ b/sdk/cdn/arm-cdn/src/models/parameters.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -20,6 +19,24 @@ export const acceptLanguage: msRest.OperationParameter = { } } }; +export const actions: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "actions" + ], + mapper: { + serializedName: "actions", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; export const apiVersion: msRest.OperationQueryParameter = { parameterPath: "apiVersion", mapper: { @@ -30,6 +47,42 @@ export const apiVersion: msRest.OperationQueryParameter = { } } }; +export const continents: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "continents" + ], + mapper: { + serializedName: "continents", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; +export const countryOrRegions: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "countryOrRegions" + ], + mapper: { + serializedName: "countryOrRegions", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; export const customDomainName: msRest.OperationURLParameter = { parameterPath: "customDomainName", mapper: { @@ -40,6 +93,60 @@ export const customDomainName: msRest.OperationURLParameter = { } } }; +export const customDomains0: msRest.OperationQueryParameter = { + parameterPath: "customDomains", + mapper: { + required: true, + serializedName: "customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; +export const customDomains1: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "customDomains" + ], + mapper: { + serializedName: "customDomains", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; +export const dateTimeBegin: msRest.OperationQueryParameter = { + parameterPath: "dateTimeBegin", + mapper: { + required: true, + serializedName: "dateTimeBegin", + type: { + name: "DateTime" + } + } +}; +export const dateTimeEnd: msRest.OperationQueryParameter = { + parameterPath: "dateTimeEnd", + mapper: { + required: true, + serializedName: "dateTimeEnd", + type: { + name: "DateTime" + } + } +}; export const endpointName: msRest.OperationURLParameter = { parameterPath: "endpointName", mapper: { @@ -50,6 +157,60 @@ export const endpointName: msRest.OperationURLParameter = { } } }; +export const granularity: msRest.OperationQueryParameter = { + parameterPath: "granularity", + mapper: { + required: true, + serializedName: "granularity", + type: { + name: "String" + } + } +}; +export const groupBy: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "groupBy" + ], + mapper: { + serializedName: "groupBy", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; +export const maxRanking: msRest.OperationQueryParameter = { + parameterPath: "maxRanking", + mapper: { + required: true, + serializedName: "maxRanking", + type: { + name: "Number" + } + } +}; +export const metrics: msRest.OperationQueryParameter = { + parameterPath: "metrics", + mapper: { + required: true, + serializedName: "metrics", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; export const nextPageLink: msRest.OperationURLParameter = { parameterPath: "nextPageLink", mapper: { @@ -104,7 +265,39 @@ export const profileName: msRest.OperationURLParameter = { } } }; -export const resourceGroupName: msRest.OperationURLParameter = { +export const protocols: msRest.OperationQueryParameter = { + parameterPath: "protocols", + mapper: { + required: true, + serializedName: "protocols", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; +export const rankings: msRest.OperationQueryParameter = { + parameterPath: "rankings", + mapper: { + required: true, + serializedName: "rankings", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; +export const resourceGroupName0: msRest.OperationURLParameter = { parameterPath: "resourceGroupName", mapper: { required: true, @@ -119,6 +312,89 @@ export const resourceGroupName: msRest.OperationURLParameter = { } } }; +export const resourceGroupName1: msRest.OperationURLParameter = { + parameterPath: "resourceGroupName", + mapper: { + required: true, + serializedName: "resourceGroupName", + constraints: { + MaxLength: 80, + MinLength: 1, + Pattern: /^[a-zA-Z0-9_\-\(\)\.]*[^\.]$/ + }, + type: { + name: "String" + } + } +}; +export const routeName: msRest.OperationURLParameter = { + parameterPath: "routeName", + mapper: { + required: true, + serializedName: "routeName", + type: { + name: "String" + } + } +}; +export const ruleName: msRest.OperationURLParameter = { + parameterPath: "ruleName", + mapper: { + required: true, + serializedName: "ruleName", + type: { + name: "String" + } + } +}; +export const ruleSetName: msRest.OperationURLParameter = { + parameterPath: "ruleSetName", + mapper: { + required: true, + serializedName: "ruleSetName", + type: { + name: "String" + } + } +}; +export const ruleTypes: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "ruleTypes" + ], + mapper: { + serializedName: "ruleTypes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + collectionFormat: msRest.QueryCollectionFormat.Multi +}; +export const secretName: msRest.OperationURLParameter = { + parameterPath: "secretName", + mapper: { + required: true, + serializedName: "secretName", + type: { + name: "String" + } + } +}; +export const securityPolicyName: msRest.OperationURLParameter = { + parameterPath: "securityPolicyName", + mapper: { + required: true, + serializedName: "securityPolicyName", + type: { + name: "String" + } + } +}; export const subscriptionId: msRest.OperationURLParameter = { parameterPath: "subscriptionId", mapper: { diff --git a/sdk/cdn/arm-cdn/src/models/policiesMappers.ts b/sdk/cdn/arm-cdn/src/models/policiesMappers.ts index fef3266d0dd8..22d2a4ded3e3 100644 --- a/sdk/cdn/arm-cdn/src/models/policiesMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/policiesMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,10 +8,20 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, CdnEndpoint, + CdnManagedHttpsParameters, CdnWebApplicationFirewallPolicy, CdnWebApplicationFirewallPolicyList, CdnWebApplicationFirewallPolicyPatchParameters, @@ -19,6 +29,8 @@ export { CloudError, CookiesMatchConditionParameters, CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -44,6 +56,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, Endpoint, EndpointPropertiesUpdateParametersDeliveryPolicy, @@ -57,7 +70,10 @@ export { HttpVersionMatchConditionParameters, IpAddressGroup, IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -68,6 +84,8 @@ export { MatchCondition, Origin, OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginUpdateParameters, PolicySettings, @@ -87,7 +105,17 @@ export { Resource, ResourceReference, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -99,5 +127,7 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, - UrlSigningParamIdentifier + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/profilesMappers.ts b/sdk/cdn/arm-cdn/src/models/profilesMappers.ts index 1ad0eed33bf2..0fe46f15073f 100644 --- a/sdk/cdn/arm-cdn/src/models/profilesMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/profilesMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. @@ -8,15 +8,27 @@ export { discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, BaseResource, CacheExpirationActionParameters, CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, CdnEndpoint, + CdnManagedHttpsParameters, CdnWebApplicationFirewallPolicy, CdnWebApplicationFirewallPolicyPatchParameters, CidrIpAddress, CookiesMatchConditionParameters, CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, CustomRule, CustomRuleList, DeepCreatedOrigin, @@ -42,6 +54,7 @@ export { DeliveryRuleUrlFileExtensionCondition, DeliveryRuleUrlFileNameCondition, DeliveryRuleUrlPathCondition, + DomainValidationProperties, EdgeNode, Endpoint, EndpointPropertiesUpdateParametersDeliveryPolicy, @@ -55,7 +68,10 @@ export { HttpVersionMatchConditionParameters, IpAddressGroup, IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, ManagedRuleDefinition, ManagedRuleGroupDefinition, ManagedRuleGroupOverride, @@ -66,6 +82,8 @@ export { MatchCondition, Origin, OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, OriginGroupUpdateParameters, OriginUpdateParameters, PolicySettings, @@ -88,9 +106,19 @@ export { ResourceUsage, ResourceUsageListResult, ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, Sku, SsoUri, SupportedOptimizationTypesListResult, + SystemData, TrackedResource, UrlFileExtensionMatchConditionParameters, UrlFileNameMatchConditionParameters, @@ -102,5 +130,7 @@ export { UrlSigningAction, UrlSigningActionParameters, UrlSigningKey, - UrlSigningParamIdentifier + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters } from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/resourceUsageOperationsMappers.ts b/sdk/cdn/arm-cdn/src/models/resourceUsageOperationsMappers.ts index a1b52f057759..2445375e57b8 100644 --- a/sdk/cdn/arm-cdn/src/models/resourceUsageOperationsMappers.ts +++ b/sdk/cdn/arm-cdn/src/models/resourceUsageOperationsMappers.ts @@ -1,6 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is regenerated. diff --git a/sdk/cdn/arm-cdn/src/models/routesMappers.ts b/sdk/cdn/arm-cdn/src/models/routesMappers.ts new file mode 100644 index 000000000000..56eaf26b4e6c --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/routesMappers.ts @@ -0,0 +1,134 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + RouteListResult, + RouteUpdateParameters, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/ruleSetsMappers.ts b/sdk/cdn/arm-cdn/src/models/ruleSetsMappers.ts new file mode 100644 index 000000000000..bd1878cb8697 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/ruleSetsMappers.ts @@ -0,0 +1,136 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + RuleSetListResult, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + Usage, + UsageName, + UsagesListResult, + UserManagedHttpsParameters +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/rulesMappers.ts b/sdk/cdn/arm-cdn/src/models/rulesMappers.ts new file mode 100644 index 000000000000..1da5a2978f3e --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/rulesMappers.ts @@ -0,0 +1,134 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleListResult, + RuleSet, + RuleUpdateParameters, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/secretsMappers.ts b/sdk/cdn/arm-cdn/src/models/secretsMappers.ts new file mode 100644 index 000000000000..c2ac366563a7 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/secretsMappers.ts @@ -0,0 +1,136 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + AFDStateProperties, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretListResult, + SecretParameters, + SecretProperties, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyProperties, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/securityPoliciesMappers.ts b/sdk/cdn/arm-cdn/src/models/securityPoliciesMappers.ts new file mode 100644 index 000000000000..3b13fa9397f8 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/securityPoliciesMappers.ts @@ -0,0 +1,136 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + AFDStateProperties, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecretProperties, + SecurityPolicy, + SecurityPolicyListResult, + SecurityPolicyParameters, + SecurityPolicyProperties, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/models/validateMappers.ts b/sdk/cdn/arm-cdn/src/models/validateMappers.ts new file mode 100644 index 000000000000..ad66512e787a --- /dev/null +++ b/sdk/cdn/arm-cdn/src/models/validateMappers.ts @@ -0,0 +1,134 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + AFDDomain, + AFDDomainHttpsParameters, + AFDEndpoint, + AFDEndpointUpdateParameters, + AfdErrorResponse, + AFDOrigin, + AFDOriginGroup, + AFDOriginGroupUpdateParameters, + AFDOriginUpdateParameters, + BaseResource, + CacheExpirationActionParameters, + CacheKeyQueryStringActionParameters, + CdnCertificateSourceParameters, + CdnEndpoint, + CdnManagedHttpsParameters, + CdnWebApplicationFirewallPolicy, + CdnWebApplicationFirewallPolicyPatchParameters, + CidrIpAddress, + CookiesMatchConditionParameters, + CustomDomain, + CustomDomainHttpsParameters, + CustomerCertificateParameters, + CustomRule, + CustomRuleList, + DeepCreatedOrigin, + DeepCreatedOriginGroup, + DeliveryRule, + DeliveryRuleAction, + DeliveryRuleCacheExpirationAction, + DeliveryRuleCacheKeyQueryStringAction, + DeliveryRuleCondition, + DeliveryRuleCookiesCondition, + DeliveryRuleHttpVersionCondition, + DeliveryRuleIsDeviceCondition, + DeliveryRulePostArgsCondition, + DeliveryRuleQueryStringCondition, + DeliveryRuleRemoteAddressCondition, + DeliveryRuleRequestBodyCondition, + DeliveryRuleRequestHeaderAction, + DeliveryRuleRequestHeaderCondition, + DeliveryRuleRequestMethodCondition, + DeliveryRuleRequestSchemeCondition, + DeliveryRuleRequestUriCondition, + DeliveryRuleResponseHeaderAction, + DeliveryRuleUrlFileExtensionCondition, + DeliveryRuleUrlFileNameCondition, + DeliveryRuleUrlPathCondition, + DomainValidationProperties, + EdgeNode, + Endpoint, + EndpointPropertiesUpdateParametersDeliveryPolicy, + EndpointPropertiesUpdateParametersWebApplicationFirewallPolicyLink, + EndpointUpdateParameters, + ErrorResponse, + GeoFilter, + HeaderActionParameters, + HealthProbeParameters, + HttpErrorRangeParameters, + HttpVersionMatchConditionParameters, + IpAddressGroup, + IsDeviceMatchConditionParameters, + KeyVaultCertificateSourceParameters, + KeyVaultSigningKeyParameters, + LoadBalancingSettingsParameters, + ManagedCertificateParameters, + ManagedRuleDefinition, + ManagedRuleGroupDefinition, + ManagedRuleGroupOverride, + ManagedRuleOverride, + ManagedRuleSet, + ManagedRuleSetDefinition, + ManagedRuleSetList, + MatchCondition, + Origin, + OriginGroup, + OriginGroupOverrideAction, + OriginGroupOverrideActionParameters, + OriginGroupUpdateParameters, + OriginUpdateParameters, + PolicySettings, + PostArgsMatchConditionParameters, + Profile, + ProfileUpdateParameters, + ProxyResource, + QueryStringMatchConditionParameters, + RateLimitRule, + RateLimitRuleList, + RemoteAddressMatchConditionParameters, + RequestBodyMatchConditionParameters, + RequestHeaderMatchConditionParameters, + RequestMethodMatchConditionParameters, + RequestSchemeMatchConditionParameters, + RequestUriMatchConditionParameters, + Resource, + ResourceReference, + ResponseBasedOriginErrorDetectionParameters, + Route, + Rule, + RuleSet, + Secret, + SecretParameters, + SecurityPolicy, + SecurityPolicyParameters, + SecurityPolicyWebApplicationFirewallAssociation, + SecurityPolicyWebApplicationFirewallParameters, + Sku, + SystemData, + TrackedResource, + UrlFileExtensionMatchConditionParameters, + UrlFileNameMatchConditionParameters, + UrlPathMatchConditionParameters, + UrlRedirectAction, + UrlRedirectActionParameters, + UrlRewriteAction, + UrlRewriteActionParameters, + UrlSigningAction, + UrlSigningActionParameters, + UrlSigningKey, + UrlSigningKeyParameters, + UrlSigningParamIdentifier, + UserManagedHttpsParameters, + ValidateSecretInput, + ValidateSecretOutput +} from "../models/mappers"; diff --git a/sdk/cdn/arm-cdn/src/operations/aFDCustomDomains.ts b/sdk/cdn/arm-cdn/src/operations/aFDCustomDomains.ts new file mode 100644 index 000000000000..9fda19968080 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/aFDCustomDomains.ts @@ -0,0 +1,475 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/aFDCustomDomainsMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a AFDCustomDomains. */ +export class AFDCustomDomains { + private readonly client: CdnManagementClientContext; + + /** + * Create a AFDCustomDomains. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists existing AzureFrontDoor domains. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + listByProfileOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing AzureFrontDoor domain with the specified domain name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, customDomainName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, customDomainName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, customDomainName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + customDomainName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new domain within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally + * @param customDomain Domain properties + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, customDomainName: string, customDomain: Models.AFDDomain, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,profileName,customDomainName,customDomain,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing domain within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, profileName: string, customDomainName: string, options?: Models.AFDCustomDomainsUpdateOptionalParams): Promise { + return this.beginUpdate(resourceGroupName,profileName,customDomainName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing AzureFrontDoor domain with the specified domain name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,customDomainName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Updates the domain validation token. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + refreshValidationToken(resourceGroupName: string, profileName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginRefreshValidationToken(resourceGroupName,profileName,customDomainName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Creates a new domain within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally + * @param customDomain Domain properties + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, customDomainName: string, customDomain: Models.AFDDomain, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + customDomainName, + customDomain, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing domain within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally + * @param [options] The optional parameters + * @returns Promise + */ + beginUpdate(resourceGroupName: string, profileName: string, customDomainName: string, options?: Models.AFDCustomDomainsBeginUpdateOptionalParams): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + customDomainName, + options + }, + beginUpdateOperationSpec, + options); + } + + /** + * Deletes an existing AzureFrontDoor domain with the specified domain name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + customDomainName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Updates the domain validation token. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param customDomainName Name of the domain under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + beginRefreshValidationToken(resourceGroupName: string, profileName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + customDomainName, + options + }, + beginRefreshValidationTokenOperationSpec, + options); + } + + /** + * Lists existing AzureFrontDoor domains. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByProfileNext(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 + */ + listByProfileNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByProfileNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByProfileOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/customDomains", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDDomainListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/customDomains/{customDomainName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.customDomainName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDDomain + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/customDomains/{customDomainName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.customDomainName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "customDomain", + mapper: { + ...Mappers.AFDDomain, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDDomain + }, + 201: { + bodyMapper: Mappers.AFDDomain + }, + 202: { + bodyMapper: Mappers.AFDDomain + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/customDomains/{customDomainName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.customDomainName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + tlsSettings: [ + "options", + "tlsSettings" + ], + azureDnsZone: [ + "options", + "azureDnsZone" + ] + }, + mapper: { + ...Mappers.AFDDomainUpdateParameters, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDDomain + }, + 202: { + bodyMapper: Mappers.AFDDomain + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/customDomains/{customDomainName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.customDomainName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginRefreshValidationTokenOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/customDomains/{customDomainName}/refreshValidationToken", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.customDomainName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ValidationToken + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByProfileNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDDomainListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/aFDEndpoints.ts b/sdk/cdn/arm-cdn/src/operations/aFDEndpoints.ts new file mode 100644 index 000000000000..150360909739 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/aFDEndpoints.ts @@ -0,0 +1,683 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/aFDEndpointsMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a AFDEndpoints. */ +export class AFDEndpoints { + private readonly client: CdnManagementClientContext; + + /** + * Create a AFDEndpoints. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists existing AzureFrontDoor endpoints. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + listByProfileOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing AzureFrontDoor endpoint with the specified endpoint name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, endpointName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, endpointName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + endpointName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new AzureFrontDoor endpoint with the specified endpoint name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param endpoint Endpoint properties + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, endpointName: string, endpoint: Models.AFDEndpoint, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,profileName,endpointName,endpoint,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing AzureFrontDoor endpoint with the specified endpoint name under the specified + * subscription, resource group and profile. Only tags can be updated after creating an endpoint. + * To update origins, use the Update Origin operation. To update origin groups, use the Update + * Origin group operation. To update domains, use the Update Custom Domain operation. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param endpointUpdateProperties Endpoint update properties + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: Models.AFDEndpointUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginUpdate(resourceGroupName,profileName,endpointName,endpointUpdateProperties,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing AzureFrontDoor endpoint with the specified endpoint name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,endpointName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Removes a content from AzureFrontDoor. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param contentPaths The path to the content to be purged. Can describe a file path or a wild + * card directory. + * @param [options] The optional parameters + * @returns Promise + */ + purgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: Models.AFDEndpointsPurgeContentOptionalParams): Promise { + return this.beginPurgeContent(resourceGroupName,profileName,endpointName,contentPaths,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsage(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, endpointName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param options The optional parameters + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, endpointName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsage(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + endpointName, + options + }, + listResourceUsageOperationSpec, + callback) as Promise; + } + + /** + * Validates the custom domain mapping to ensure it maps to the correct CDN endpoint in DNS. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param hostName The host name of the custom domain. Must be a domain name. + * @param [options] The optional parameters + * @returns Promise + */ + validateCustomDomain(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param hostName The host name of the custom domain. Must be a domain name. + * @param callback The callback + */ + validateCustomDomain(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param hostName The host name of the custom domain. Must be a domain name. + * @param options The optional parameters + * @param callback The callback + */ + validateCustomDomain(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + validateCustomDomain(resourceGroupName: string, profileName: string, endpointName: string, hostName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + endpointName, + hostName, + options + }, + validateCustomDomainOperationSpec, + callback) as Promise; + } + + /** + * Creates a new AzureFrontDoor endpoint with the specified endpoint name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param endpoint Endpoint properties + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, endpointName: string, endpoint: Models.AFDEndpoint, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + endpoint, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing AzureFrontDoor endpoint with the specified endpoint name under the specified + * subscription, resource group and profile. Only tags can be updated after creating an endpoint. + * To update origins, use the Update Origin operation. To update origin groups, use the Update + * Origin group operation. To update domains, use the Update Custom Domain operation. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param endpointUpdateProperties Endpoint update properties + * @param [options] The optional parameters + * @returns Promise + */ + beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, endpointUpdateProperties: Models.AFDEndpointUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + endpointUpdateProperties, + options + }, + beginUpdateOperationSpec, + options); + } + + /** + * Deletes an existing AzureFrontDoor endpoint with the specified endpoint name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Removes a content from AzureFrontDoor. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param contentPaths The path to the content to be purged. Can describe a file path or a wild + * card directory. + * @param [options] The optional parameters + * @returns Promise + */ + beginPurgeContent(resourceGroupName: string, profileName: string, endpointName: string, contentPaths: string[], options?: Models.AFDEndpointsBeginPurgeContentOptionalParams): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + contentPaths, + options + }, + beginPurgeContentOperationSpec, + options); + } + + /** + * Lists existing AzureFrontDoor endpoints. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByProfileNext(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 + */ + listByProfileNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByProfileNextOperationSpec, + callback) as Promise; + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listResourceUsageNext(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 + */ + listResourceUsageNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listResourceUsageNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByProfileOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDEndpointListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDEndpoint + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listResourceUsageOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/usages", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const validateCustomDomainOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/validateCustomDomain", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + hostName: "hostName" + }, + mapper: { + ...Mappers.ValidateCustomDomainInput, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.ValidateCustomDomainOutput + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "endpoint", + mapper: { + ...Mappers.AFDEndpoint, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDEndpoint + }, + 201: { + bodyMapper: Mappers.AFDEndpoint + }, + 202: { + bodyMapper: Mappers.AFDEndpoint + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "endpointUpdateProperties", + mapper: { + ...Mappers.AFDEndpointUpdateParameters, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDEndpoint + }, + 202: { + bodyMapper: Mappers.AFDEndpoint + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginPurgeContentOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/purge", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + contentPaths: "contentPaths", + domains: [ + "options", + "domains" + ] + }, + mapper: { + ...Mappers.AfdPurgeParameters, + required: true + } + }, + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByProfileNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDEndpointListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listResourceUsageNextOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/aFDOriginGroups.ts b/sdk/cdn/arm-cdn/src/operations/aFDOriginGroups.ts new file mode 100644 index 000000000000..a53a30d4f7cc --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/aFDOriginGroups.ts @@ -0,0 +1,521 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/aFDOriginGroupsMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a AFDOriginGroups. */ +export class AFDOriginGroups { + private readonly client: CdnManagementClientContext; + + /** + * Create a AFDOriginGroups. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists all of the existing origin groups within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + listByProfileOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing origin group within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, originGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, originGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + originGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new origin group within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param originGroup Origin group properties + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, originGroupName: string, originGroup: Models.AFDOriginGroup, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,profileName,originGroupName,originGroup,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing origin group within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originGroupUpdateProperties Origin group properties + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, profileName: string, originGroupName: string, originGroupUpdateProperties: Models.AFDOriginGroupUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginUpdate(resourceGroupName,profileName,originGroupName,originGroupUpdateProperties,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing origin group within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,originGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsage(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, originGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param options The optional parameters + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, originGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsage(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + originGroupName, + options + }, + listResourceUsageOperationSpec, + callback) as Promise; + } + + /** + * Creates a new origin group within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the endpoint. + * @param originGroup Origin group properties + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, originGroupName: string, originGroup: Models.AFDOriginGroup, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + originGroupName, + originGroup, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing origin group within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originGroupUpdateProperties Origin group properties + * @param [options] The optional parameters + * @returns Promise + */ + beginUpdate(resourceGroupName: string, profileName: string, originGroupName: string, originGroupUpdateProperties: Models.AFDOriginGroupUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + originGroupName, + originGroupUpdateProperties, + options + }, + beginUpdateOperationSpec, + options); + } + + /** + * Deletes an existing origin group within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + originGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists all of the existing origin groups within a profile. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByProfileNext(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 + */ + listByProfileNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByProfileNextOperationSpec, + callback) as Promise; + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listResourceUsageNext(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 + */ + listResourceUsageNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listResourceUsageNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByProfileOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDOriginGroupListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDOriginGroup + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listResourceUsageOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}/usages", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "originGroup", + mapper: { + ...Mappers.AFDOriginGroup, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDOriginGroup + }, + 201: { + bodyMapper: Mappers.AFDOriginGroup + }, + 202: { + bodyMapper: Mappers.AFDOriginGroup + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "originGroupUpdateProperties", + mapper: { + ...Mappers.AFDOriginGroupUpdateParameters, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDOriginGroup + }, + 202: { + bodyMapper: Mappers.AFDOriginGroup + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByProfileNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDOriginGroupListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listResourceUsageNextOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/aFDOrigins.ts b/sdk/cdn/arm-cdn/src/operations/aFDOrigins.ts new file mode 100644 index 000000000000..e0e71a2b9c31 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/aFDOrigins.ts @@ -0,0 +1,429 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/aFDOriginsMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a AFDOrigins. */ +export class AFDOrigins { + private readonly client: CdnManagementClientContext; + + /** + * Create a AFDOrigins. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists all of the existing origins within an origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param [options] The optional parameters + * @returns Promise + */ + listByOriginGroup(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param callback The callback + */ + listByOriginGroup(resourceGroupName: string, profileName: string, originGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param options The optional parameters + * @param callback The callback + */ + listByOriginGroup(resourceGroupName: string, profileName: string, originGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByOriginGroup(resourceGroupName: string, profileName: string, originGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + originGroupName, + options + }, + listByOriginGroupOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing origin within an origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin which is unique within the profile. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin which is unique within the profile. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin which is unique within the profile. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + originGroupName, + originName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new origin within the specified origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin that is unique within the profile. + * @param origin Origin properties + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, origin: Models.AFDOrigin, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,profileName,originGroupName,originName,origin,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing origin within an origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin which is unique within the profile. + * @param originUpdateProperties Origin properties + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, originUpdateProperties: Models.AFDOriginUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginUpdate(resourceGroupName,profileName,originGroupName,originName,originUpdateProperties,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing origin within an origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin which is unique within the profile. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,originGroupName,originName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates a new origin within the specified origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin that is unique within the profile. + * @param origin Origin properties + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, origin: Models.AFDOrigin, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + originGroupName, + originName, + origin, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing origin within an origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin which is unique within the profile. + * @param originUpdateProperties Origin properties + * @param [options] The optional parameters + * @returns Promise + */ + beginUpdate(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, originUpdateProperties: Models.AFDOriginUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + originGroupName, + originName, + originUpdateProperties, + options + }, + beginUpdateOperationSpec, + options); + } + + /** + * Deletes an existing origin within an origin group. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param originGroupName Name of the origin group which is unique within the profile. + * @param originName Name of the origin which is unique within the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, originGroupName: string, originName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + originGroupName, + originName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists all of the existing origins within an origin group. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByOriginGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByOriginGroupNext(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 + */ + listByOriginGroupNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByOriginGroupNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByOriginGroupNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByOriginGroupOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}/origins", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDOriginListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}/origins/{originName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.originName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDOrigin + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}/origins/{originName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.originName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "origin", + mapper: { + ...Mappers.AFDOrigin, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDOrigin + }, + 201: { + bodyMapper: Mappers.AFDOrigin + }, + 202: { + bodyMapper: Mappers.AFDOrigin + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}/origins/{originName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.originName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "originUpdateProperties", + mapper: { + ...Mappers.AFDOriginUpdateParameters, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.AFDOrigin + }, + 202: { + bodyMapper: Mappers.AFDOrigin + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/originGroups/{originGroupName}/origins/{originName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.originGroupName, + Parameters.originName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByOriginGroupNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AFDOriginListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/aFDProfiles.ts b/sdk/cdn/arm-cdn/src/operations/aFDProfiles.ts new file mode 100644 index 000000000000..308ff6de6181 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/aFDProfiles.ts @@ -0,0 +1,208 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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/aFDProfilesMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a AFDProfiles. */ +export class AFDProfiles { + private readonly client: CdnManagementClientContext; + + /** + * Create a AFDProfiles. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsage(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsage(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + listResourceUsageOperationSpec, + callback) as Promise; + } + + /** + * Validates the custom domain mapping to ensure it maps to the correct CDN endpoint in DNS. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param hostName The host name of the custom domain. Must be a domain name. + * @param [options] The optional parameters + * @returns Promise + */ + checkHostNameAvailability(resourceGroupName: string, profileName: string, hostName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param hostName The host name of the custom domain. Must be a domain name. + * @param callback The callback + */ + checkHostNameAvailability(resourceGroupName: string, profileName: string, hostName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param hostName The host name of the custom domain. Must be a domain name. + * @param options The optional parameters + * @param callback The callback + */ + checkHostNameAvailability(resourceGroupName: string, profileName: string, hostName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + checkHostNameAvailability(resourceGroupName: string, profileName: string, hostName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + hostName, + options + }, + checkHostNameAvailabilityOperationSpec, + callback) as Promise; + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listResourceUsageNext(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 + */ + listResourceUsageNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listResourceUsageNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listResourceUsageOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/usages", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const checkHostNameAvailabilityOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/checkHostNameAvailability", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + hostName: "hostName" + }, + mapper: { + ...Mappers.ValidateCustomDomainInput, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.ValidateCustomDomainOutput + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listResourceUsageNextOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/customDomains.ts b/sdk/cdn/arm-cdn/src/operations/customDomains.ts index c05b4b4c92bc..24db45b8c079 100644 --- a/sdk/cdn/arm-cdn/src/operations/customDomains.ts +++ b/sdk/cdn/arm-cdn/src/operations/customDomains.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -14,7 +13,6 @@ import * as Models from "../models"; import * as Mappers from "../models/customDomainsMappers"; import * as Parameters from "../models/parameters"; import { CdnManagementClientContext } from "../cdnManagementClientContext"; -import { Profiles } from "./profiles"; /** Class representing a CustomDomains. */ export class CustomDomains { @@ -115,7 +113,7 @@ export class CustomDomains { * @returns Promise */ create(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: msRest.RequestOptionsBase): Promise { - return this.beginCreate(resourceGroupName, profileName, endpointName, customDomainName, hostName, options) + return this.beginCreate(resourceGroupName,profileName,endpointName,customDomainName,hostName,options) .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; } @@ -129,7 +127,7 @@ export class CustomDomains { * @returns Promise */ deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { - return this.beginDeleteMethod(resourceGroupName, profileName, endpointName, customDomainName, options) + return this.beginDeleteMethod(resourceGroupName,profileName,endpointName,customDomainName,options) .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; } @@ -142,129 +140,95 @@ export class CustomDomains { * @param [options] The optional parameters * @returns Promise */ - disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise; + disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDisableCustomHttps(resourceGroupName,profileName,endpointName,customDomainName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + /** + * Enable https delivery of the custom domain. * @param resourceGroupName Name of the Resource group within the Azure subscription. * @param profileName Name of the CDN profile which is unique within the resource group. * @param endpointName Name of the endpoint under the profile which is unique globally. * @param customDomainName Name of the custom domain within an endpoint. - * @param callback The callback + * @param [options] The optional parameters + * @returns Promise */ - disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, callback: msRest.ServiceCallback): void; + enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: Models.CustomDomainsEnableCustomHttpsOptionalParams): Promise { + return this.beginEnableCustomHttps(resourceGroupName,profileName,endpointName,customDomainName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + /** + * Creates a new custom domain within an endpoint. * @param resourceGroupName Name of the Resource group within the Azure subscription. * @param profileName Name of the CDN profile which is unique within the resource group. * @param endpointName Name of the endpoint under the profile which is unique globally. * @param customDomainName Name of the custom domain within an endpoint. - * @param options The optional parameters - * @param callback The callback + * @param hostName The host name of the custom domain. Must be a domain name. + * @param [options] The optional parameters + * @returns Promise */ - disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; - disableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { - return this.client.sendOperationRequest( + beginCreate(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( { resourceGroupName, profileName, endpointName, customDomainName, + hostName, options }, - disableCustomHttpsOperationSpec, - callback) as Promise; + beginCreateOperationSpec, + options); } /** - * Enable https delivery of the custom domain. + * Deletes an existing custom domain within an endpoint. * @param resourceGroupName Name of the Resource group within the Azure subscription. * @param profileName Name of the CDN profile which is unique within the resource group. * @param endpointName Name of the endpoint under the profile which is unique globally. * @param customDomainName Name of the custom domain within an endpoint. * @param [options] The optional parameters - * @returns Promise - */ - enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: Models.CustomDomainsEnableCustomHttpsOptionalParams): Promise; - /** - * @param resourceGroupName Name of the Resource group within the Azure subscription. - * @param profileName Name of the CDN profile which is unique within the resource group. - * @param endpointName Name of the endpoint under the profile which is unique globally. - * @param customDomainName Name of the custom domain within an endpoint. - * @param callback The callback - */ - enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, callback: msRest.ServiceCallback): void; - /** - * @param resourceGroupName Name of the Resource group within the Azure subscription. - * @param profileName Name of the CDN profile which is unique within the resource group. - * @param endpointName Name of the endpoint under the profile which is unique globally. - * @param customDomainName Name of the custom domain within an endpoint. - * @param options The optional parameters - * @param callback The callback + * @returns Promise */ - enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options: Models.CustomDomainsEnableCustomHttpsOptionalParams, callback: msRest.ServiceCallback): void; - enableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: Models.CustomDomainsEnableCustomHttpsOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { - // #region Added default values to add backwards compatibility - let newOptions: Models.CustomDomainsEnableCustomHttpsOptionalParams = {}; - - if (typeof options === "function") { - callback = options; - } else { - newOptions = options as Models.CustomDomainsEnableCustomHttpsOptionalParams; - } - - if (!newOptions) { - newOptions = {}; - } - - let optionsPreparationPromise = Promise.resolve(options); - - if (!newOptions.customDomainHttpsParameters) { - let profiles = new Profiles(this.client); - optionsPreparationPromise = profiles.get(resourceGroupName, profileName).then(profile => { - newOptions.customDomainHttpsParameters = getDefaultCustomDomainHttpsParameters(profile); - return newOptions; - }) - } - - return optionsPreparationPromise.then(options => - this.client.sendOperationRequest( - { - resourceGroupName, - profileName, - endpointName, - customDomainName, - options - }, - enableCustomHttpsOperationSpec, - callback) as Promise - ); - // #endregion + beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + customDomainName, + options + }, + beginDeleteMethodOperationSpec, + options); } /** - * Creates a new custom domain within an endpoint. + * Disable https delivery of the custom domain. * @param resourceGroupName Name of the Resource group within the Azure subscription. * @param profileName Name of the CDN profile which is unique within the resource group. * @param endpointName Name of the endpoint under the profile which is unique globally. * @param customDomainName Name of the custom domain within an endpoint. - * @param hostName The host name of the custom domain. Must be a domain name. * @param [options] The optional parameters * @returns Promise */ - beginCreate(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, hostName: string, options?: msRest.RequestOptionsBase): Promise { + beginDisableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { return this.client.sendLRORequest( { resourceGroupName, profileName, endpointName, customDomainName, - hostName, options }, - beginCreateOperationSpec, + beginDisableCustomHttpsOperationSpec, options); } /** - * Deletes an existing custom domain within an endpoint. + * Enable https delivery of the custom domain. * @param resourceGroupName Name of the Resource group within the Azure subscription. * @param profileName Name of the CDN profile which is unique within the resource group. * @param endpointName Name of the endpoint under the profile which is unique globally. @@ -272,7 +236,7 @@ export class CustomDomains { * @param [options] The optional parameters * @returns Promise */ - beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: msRest.RequestOptionsBase): Promise { + beginEnableCustomHttps(resourceGroupName: string, profileName: string, endpointName: string, customDomainName: string, options?: Models.CustomDomainsBeginEnableCustomHttpsOptionalParams): Promise { return this.client.sendLRORequest( { resourceGroupName, @@ -281,7 +245,7 @@ export class CustomDomains { customDomainName, options }, - beginDeleteMethodOperationSpec, + beginEnableCustomHttpsOperationSpec, options); } @@ -314,53 +278,13 @@ export class CustomDomains { } } -// #region Added default values to add backwards compatibility -class SkuNames { - public static get standard_microsoft() { return "Standard_Microsoft"; } - public static get standard_verizon() { return "Standard_Verizon"; } - public static get standard_akamai() { return "Standard_Akamai"; } -} - -function getDefaultCustomDomainHttpsParameters(profile: Models.Profile): Models.CdnManagedHttpsParameters | undefined { - switch (profile.sku.name) { - case SkuNames.standard_microsoft: - return { - certificateSource: "Cdn", - certificateSourceParameters: { - certificateType: "Dedicated" - }, - protocolType: "ServerNameIndication" - } - case SkuNames.standard_akamai: - return { - certificateSource: "Cdn", - certificateSourceParameters: { - certificateType: "Shared" - }, - protocolType: "ServerNameIndication" - } - case SkuNames.standard_verizon: - return { - certificateSource: "Cdn", - certificateSourceParameters: { - certificateType: "Shared" - }, - protocolType: "IPBased" - } - default: - return undefined; - } -} - -// #endregion - // Operation Specifications const serializer = new msRest.Serializer(Mappers); const listByEndpointOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -386,7 +310,7 @@ const getOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.customDomainName, @@ -409,11 +333,11 @@ const getOperationSpec: msRest.OperationSpec = { serializer }; -const disableCustomHttpsOperationSpec: msRest.OperationSpec = { - httpMethod: "POST", - path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}/disableCustomHttps", +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.customDomainName, @@ -425,8 +349,22 @@ const disableCustomHttpsOperationSpec: msRest.OperationSpec = { headerParameters: [ Parameters.acceptLanguage ], + requestBody: { + parameterPath: { + hostName: "hostName" + }, + mapper: { + ...Mappers.CustomDomainParameters, + required: true + } + }, responses: { - 200: {}, + 200: { + bodyMapper: Mappers.CustomDomain + }, + 201: { + bodyMapper: Mappers.CustomDomain + }, 202: { bodyMapper: Mappers.CustomDomain }, @@ -437,11 +375,11 @@ const disableCustomHttpsOperationSpec: msRest.OperationSpec = { serializer }; -const enableCustomHttpsOperationSpec: msRest.OperationSpec = { - httpMethod: "POST", - path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}/enableCustomHttps", +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.customDomainName, @@ -453,18 +391,12 @@ const enableCustomHttpsOperationSpec: msRest.OperationSpec = { headerParameters: [ Parameters.acceptLanguage ], - requestBody: { - parameterPath: [ - "options", - "customDomainHttpsParameters" - ], - mapper: Mappers.CustomDomainHttpsParameters - }, responses: { 200: {}, 202: { bodyMapper: Mappers.CustomDomain }, + 204: {}, default: { bodyMapper: Mappers.ErrorResponse } @@ -472,11 +404,11 @@ const enableCustomHttpsOperationSpec: msRest.OperationSpec = { serializer }; -const beginCreateOperationSpec: msRest.OperationSpec = { - httpMethod: "PUT", - path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}", +const beginDisableCustomHttpsOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}/disableCustomHttps", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.customDomainName, @@ -488,22 +420,8 @@ const beginCreateOperationSpec: msRest.OperationSpec = { headerParameters: [ Parameters.acceptLanguage ], - requestBody: { - parameterPath: { - hostName: "hostName" - }, - mapper: { - ...Mappers.CustomDomainParameters, - required: true - } - }, responses: { - 200: { - bodyMapper: Mappers.CustomDomain - }, - 201: { - bodyMapper: Mappers.CustomDomain - }, + 200: {}, 202: { bodyMapper: Mappers.CustomDomain }, @@ -514,11 +432,11 @@ const beginCreateOperationSpec: msRest.OperationSpec = { serializer }; -const beginDeleteMethodOperationSpec: msRest.OperationSpec = { - httpMethod: "DELETE", - path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}", +const beginEnableCustomHttpsOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}/enableCustomHttps", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.customDomainName, @@ -530,12 +448,18 @@ const beginDeleteMethodOperationSpec: msRest.OperationSpec = { headerParameters: [ Parameters.acceptLanguage ], + requestBody: { + parameterPath: [ + "options", + "customDomainHttpsParameters" + ], + mapper: Mappers.CustomDomainHttpsParameters + }, responses: { 200: {}, 202: { bodyMapper: Mappers.CustomDomain }, - 204: {}, default: { bodyMapper: Mappers.ErrorResponse } @@ -550,6 +474,9 @@ const listByEndpointNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/edgeNodes.ts b/sdk/cdn/arm-cdn/src/operations/edgeNodes.ts index 282fd57f895a..ace8cd2a8509 100644 --- a/sdk/cdn/arm-cdn/src/operations/edgeNodes.ts +++ b/sdk/cdn/arm-cdn/src/operations/edgeNodes.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -110,6 +109,9 @@ const listNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/endpoints.ts b/sdk/cdn/arm-cdn/src/operations/endpoints.ts index fc412606a7d3..c942f92ca281 100644 --- a/sdk/cdn/arm-cdn/src/operations/endpoints.ts +++ b/sdk/cdn/arm-cdn/src/operations/endpoints.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -492,7 +491,7 @@ const listByProfileOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -517,7 +516,7 @@ const getOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -543,7 +542,7 @@ const validateCustomDomainOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/validateCustomDomain", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -578,7 +577,7 @@ const listResourceUsageOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/checkResourceUsage", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -604,7 +603,7 @@ const beginCreateOperationSpec: msRest.OperationSpec = { httpMethod: "PUT", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -643,7 +642,7 @@ const beginUpdateOperationSpec: msRest.OperationSpec = { httpMethod: "PATCH", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -679,7 +678,7 @@ const beginDeleteMethodOperationSpec: msRest.OperationSpec = { httpMethod: "DELETE", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -704,7 +703,7 @@ const beginStartOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/start", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -733,7 +732,7 @@ const beginStopOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/stop", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -762,7 +761,7 @@ const beginPurgeContentOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/purge", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -796,7 +795,7 @@ const beginLoadContentOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/load", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -833,6 +832,9 @@ const listByProfileNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], @@ -854,6 +856,9 @@ const listResourceUsageNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/index.ts b/sdk/cdn/arm-cdn/src/operations/index.ts index 6cb01556e7ca..98718b34f12a 100644 --- a/sdk/cdn/arm-cdn/src/operations/index.ts +++ b/sdk/cdn/arm-cdn/src/operations/index.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -16,5 +15,17 @@ export * from "./customDomains"; export * from "./resourceUsageOperations"; export * from "./operations"; export * from "./edgeNodes"; +export * from "./aFDProfiles"; +export * from "./aFDCustomDomains"; +export * from "./aFDEndpoints"; +export * from "./aFDOriginGroups"; +export * from "./aFDOrigins"; +export * from "./routes"; +export * from "./ruleSets"; +export * from "./rules"; +export * from "./securityPolicies"; +export * from "./secrets"; +export * from "./validate"; +export * from "./logAnalytics"; export * from "./policies"; export * from "./managedRuleSets"; diff --git a/sdk/cdn/arm-cdn/src/operations/logAnalytics.ts b/sdk/cdn/arm-cdn/src/operations/logAnalytics.ts new file mode 100644 index 000000000000..824bade29bd3 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/logAnalytics.ts @@ -0,0 +1,480 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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/logAnalyticsMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a LogAnalytics. */ +export class LogAnalytics { + private readonly client: CdnManagementClientContext; + + /** + * Create a LogAnalytics. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Get log report for AFD profile + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param granularity Possible values include: 'PT5M', 'PT1H', 'P1D' + * @param customDomains + * @param protocols + * @param [options] The optional parameters + * @returns Promise + */ + getLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.LogMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.LogMetricsGranularity, customDomains: string[], protocols: string[], options?: Models.LogAnalyticsGetLogAnalyticsMetricsOptionalParams): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param granularity Possible values include: 'PT5M', 'PT1H', 'P1D' + * @param customDomains + * @param protocols + * @param callback The callback + */ + getLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.LogMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.LogMetricsGranularity, customDomains: string[], protocols: string[], callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param granularity Possible values include: 'PT5M', 'PT1H', 'P1D' + * @param customDomains + * @param protocols + * @param options The optional parameters + * @param callback The callback + */ + getLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.LogMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.LogMetricsGranularity, customDomains: string[], protocols: string[], options: Models.LogAnalyticsGetLogAnalyticsMetricsOptionalParams, callback: msRest.ServiceCallback): void; + getLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.LogMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.LogMetricsGranularity, customDomains: string[], protocols: string[], options?: Models.LogAnalyticsGetLogAnalyticsMetricsOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + metrics, + dateTimeBegin, + dateTimeEnd, + granularity, + customDomains, + protocols, + options + }, + getLogAnalyticsMetricsOperationSpec, + callback) as Promise; + } + + /** + * Get log analytics ranking report for AFD profile + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param rankings + * @param metrics + * @param maxRanking + * @param dateTimeBegin + * @param dateTimeEnd + * @param [options] The optional parameters + * @returns Promise + */ + getLogAnalyticsRankings(resourceGroupName: string, profileName: string, rankings: Models.LogRanking[], metrics: Models.LogRankingMetric[], maxRanking: number, dateTimeBegin: Date | string, dateTimeEnd: Date | string, options?: Models.LogAnalyticsGetLogAnalyticsRankingsOptionalParams): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param rankings + * @param metrics + * @param maxRanking + * @param dateTimeBegin + * @param dateTimeEnd + * @param callback The callback + */ + getLogAnalyticsRankings(resourceGroupName: string, profileName: string, rankings: Models.LogRanking[], metrics: Models.LogRankingMetric[], maxRanking: number, dateTimeBegin: Date | string, dateTimeEnd: Date | string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param rankings + * @param metrics + * @param maxRanking + * @param dateTimeBegin + * @param dateTimeEnd + * @param options The optional parameters + * @param callback The callback + */ + getLogAnalyticsRankings(resourceGroupName: string, profileName: string, rankings: Models.LogRanking[], metrics: Models.LogRankingMetric[], maxRanking: number, dateTimeBegin: Date | string, dateTimeEnd: Date | string, options: Models.LogAnalyticsGetLogAnalyticsRankingsOptionalParams, callback: msRest.ServiceCallback): void; + getLogAnalyticsRankings(resourceGroupName: string, profileName: string, rankings: Models.LogRanking[], metrics: Models.LogRankingMetric[], maxRanking: number, dateTimeBegin: Date | string, dateTimeEnd: Date | string, options?: Models.LogAnalyticsGetLogAnalyticsRankingsOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + rankings, + metrics, + maxRanking, + dateTimeBegin, + dateTimeEnd, + options + }, + getLogAnalyticsRankingsOperationSpec, + callback) as Promise; + } + + /** + * Get all available location names for AFD log analytics report. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + getLogAnalyticsLocations(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + getLogAnalyticsLocations(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + getLogAnalyticsLocations(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + getLogAnalyticsLocations(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + getLogAnalyticsLocationsOperationSpec, + callback) as Promise; + } + + /** + * Get all endpoints and custom domains available for AFD log report + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + getLogAnalyticsResources(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + getLogAnalyticsResources(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + getLogAnalyticsResources(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + getLogAnalyticsResources(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + getLogAnalyticsResourcesOperationSpec, + callback) as Promise; + } + + /** + * Get Waf related log analytics report for AFD profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param granularity Possible values include: 'PT5M', 'PT1H', 'P1D' + * @param [options] The optional parameters + * @returns Promise + */ + getWafLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.WafGranularity, options?: Models.LogAnalyticsGetWafLogAnalyticsMetricsOptionalParams): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param granularity Possible values include: 'PT5M', 'PT1H', 'P1D' + * @param callback The callback + */ + getWafLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.WafGranularity, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param granularity Possible values include: 'PT5M', 'PT1H', 'P1D' + * @param options The optional parameters + * @param callback The callback + */ + getWafLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.WafGranularity, options: Models.LogAnalyticsGetWafLogAnalyticsMetricsOptionalParams, callback: msRest.ServiceCallback): void; + getWafLogAnalyticsMetrics(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, granularity: Models.WafGranularity, options?: Models.LogAnalyticsGetWafLogAnalyticsMetricsOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + metrics, + dateTimeBegin, + dateTimeEnd, + granularity, + options + }, + getWafLogAnalyticsMetricsOperationSpec, + callback) as Promise; + } + + /** + * Get WAF log analytics charts for AFD profile + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param maxRanking + * @param rankings + * @param [options] The optional parameters + * @returns Promise + */ + getWafLogAnalyticsRankings(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, maxRanking: number, rankings: Models.WafRankingType[], options?: Models.LogAnalyticsGetWafLogAnalyticsRankingsOptionalParams): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param maxRanking + * @param rankings + * @param callback The callback + */ + getWafLogAnalyticsRankings(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, maxRanking: number, rankings: Models.WafRankingType[], callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param metrics + * @param dateTimeBegin + * @param dateTimeEnd + * @param maxRanking + * @param rankings + * @param options The optional parameters + * @param callback The callback + */ + getWafLogAnalyticsRankings(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, maxRanking: number, rankings: Models.WafRankingType[], options: Models.LogAnalyticsGetWafLogAnalyticsRankingsOptionalParams, callback: msRest.ServiceCallback): void; + getWafLogAnalyticsRankings(resourceGroupName: string, profileName: string, metrics: Models.WafMetric[], dateTimeBegin: Date | string, dateTimeEnd: Date | string, maxRanking: number, rankings: Models.WafRankingType[], options?: Models.LogAnalyticsGetWafLogAnalyticsRankingsOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + metrics, + dateTimeBegin, + dateTimeEnd, + maxRanking, + rankings, + options + }, + getWafLogAnalyticsRankingsOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const getLogAnalyticsMetricsOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getLogAnalyticsMetrics", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName0, + Parameters.profileName + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.metrics, + Parameters.dateTimeBegin, + Parameters.dateTimeEnd, + Parameters.granularity, + Parameters.groupBy, + Parameters.continents, + Parameters.countryOrRegions, + Parameters.customDomains0, + Parameters.protocols + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.MetricsResponse + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getLogAnalyticsRankingsOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getLogAnalyticsRankings", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName0, + Parameters.profileName + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.rankings, + Parameters.metrics, + Parameters.maxRanking, + Parameters.dateTimeBegin, + Parameters.dateTimeEnd, + Parameters.customDomains1 + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RankingsResponse + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getLogAnalyticsLocationsOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getLogAnalyticsLocations", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName0, + Parameters.profileName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ContinentsResponse + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getLogAnalyticsResourcesOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getLogAnalyticsResources", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName0, + Parameters.profileName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ResourcesResponse + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getWafLogAnalyticsMetricsOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getWafLogAnalyticsMetrics", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName0, + Parameters.profileName + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.metrics, + Parameters.dateTimeBegin, + Parameters.dateTimeEnd, + Parameters.granularity, + Parameters.actions, + Parameters.groupBy, + Parameters.ruleTypes + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.WafMetricsResponse + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getWafLogAnalyticsRankingsOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getWafLogAnalyticsRankings", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName0, + Parameters.profileName + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.metrics, + Parameters.dateTimeBegin, + Parameters.dateTimeEnd, + Parameters.maxRanking, + Parameters.rankings, + Parameters.actions, + Parameters.ruleTypes + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.WafRankingsResponse + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/managedRuleSets.ts b/sdk/cdn/arm-cdn/src/operations/managedRuleSets.ts index 55a5f62e5faa..5ce068169691 100644 --- a/sdk/cdn/arm-cdn/src/operations/managedRuleSets.ts +++ b/sdk/cdn/arm-cdn/src/operations/managedRuleSets.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -111,6 +110,9 @@ const listNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/operations.ts b/sdk/cdn/arm-cdn/src/operations/operations.ts index 09c0ecfd5439..93ce3bee154d 100644 --- a/sdk/cdn/arm-cdn/src/operations/operations.ts +++ b/sdk/cdn/arm-cdn/src/operations/operations.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -108,6 +107,9 @@ const listNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/originGroups.ts b/sdk/cdn/arm-cdn/src/operations/originGroups.ts index 8592b28f1712..00e2c5ac0e7c 100644 --- a/sdk/cdn/arm-cdn/src/operations/originGroups.ts +++ b/sdk/cdn/arm-cdn/src/operations/originGroups.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -252,7 +251,7 @@ const listByEndpointOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/originGroups", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -278,7 +277,7 @@ const getOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/originGroups/{originGroupName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originGroupName, @@ -305,7 +304,7 @@ const beginCreateOperationSpec: msRest.OperationSpec = { httpMethod: "PUT", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/originGroups/{originGroupName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originGroupName, @@ -345,7 +344,7 @@ const beginUpdateOperationSpec: msRest.OperationSpec = { httpMethod: "PATCH", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/originGroups/{originGroupName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originGroupName, @@ -382,7 +381,7 @@ const beginDeleteMethodOperationSpec: msRest.OperationSpec = { httpMethod: "DELETE", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/originGroups/{originGroupName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originGroupName, @@ -411,6 +410,9 @@ const listByEndpointNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/origins.ts b/sdk/cdn/arm-cdn/src/operations/origins.ts index 340e6e88b3a4..6cf0cdf7d53c 100644 --- a/sdk/cdn/arm-cdn/src/operations/origins.ts +++ b/sdk/cdn/arm-cdn/src/operations/origins.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -252,7 +251,7 @@ const listByEndpointOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.subscriptionId @@ -278,7 +277,7 @@ const getOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins/{originName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originName, @@ -305,7 +304,7 @@ const beginCreateOperationSpec: msRest.OperationSpec = { httpMethod: "PUT", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins/{originName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originName, @@ -345,7 +344,7 @@ const beginUpdateOperationSpec: msRest.OperationSpec = { httpMethod: "PATCH", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins/{originName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originName, @@ -382,7 +381,7 @@ const beginDeleteMethodOperationSpec: msRest.OperationSpec = { httpMethod: "DELETE", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/origins/{originName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.endpointName, Parameters.originName, @@ -411,6 +410,9 @@ const listByEndpointNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/policies.ts b/sdk/cdn/arm-cdn/src/operations/policies.ts index 51e412994bdc..1c4b844064ce 100644 --- a/sdk/cdn/arm-cdn/src/operations/policies.ts +++ b/sdk/cdn/arm-cdn/src/operations/policies.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -219,7 +218,7 @@ const listOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/CdnWebApplicationFirewallPolicies", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName1, Parameters.subscriptionId ], queryParameters: [ @@ -243,7 +242,7 @@ const getOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/CdnWebApplicationFirewallPolicies/{policyName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName1, Parameters.policyName, Parameters.subscriptionId ], @@ -268,7 +267,7 @@ const deleteMethodOperationSpec: msRest.OperationSpec = { httpMethod: "DELETE", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/CdnWebApplicationFirewallPolicies/{policyName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName1, Parameters.policyName, Parameters.subscriptionId ], @@ -292,7 +291,7 @@ const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { httpMethod: "PUT", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/CdnWebApplicationFirewallPolicies/{policyName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName1, Parameters.policyName, Parameters.subscriptionId ], @@ -330,7 +329,7 @@ const beginUpdateOperationSpec: msRest.OperationSpec = { httpMethod: "PATCH", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/CdnWebApplicationFirewallPolicies/{policyName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName1, Parameters.policyName, Parameters.subscriptionId ], @@ -373,6 +372,9 @@ const listNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/profiles.ts b/sdk/cdn/arm-cdn/src/operations/profiles.ts index cda521b7a1d0..573dae8d3766 100644 --- a/sdk/cdn/arm-cdn/src/operations/profiles.ts +++ b/sdk/cdn/arm-cdn/src/operations/profiles.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -426,7 +425,7 @@ const listByResourceGroupOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.subscriptionId ], queryParameters: [ @@ -450,7 +449,7 @@ const getOperationSpec: msRest.OperationSpec = { httpMethod: "GET", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -475,7 +474,7 @@ const generateSsoUriOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/generateSsoUri", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -500,7 +499,7 @@ const listSupportedOptimizationTypesOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/getSupportedOptimizationTypes", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -525,7 +524,7 @@ const listResourceUsageOperationSpec: msRest.OperationSpec = { httpMethod: "POST", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/checkResourceUsage", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -550,7 +549,7 @@ const beginCreateOperationSpec: msRest.OperationSpec = { httpMethod: "PUT", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -588,7 +587,7 @@ const beginUpdateOperationSpec: msRest.OperationSpec = { httpMethod: "PATCH", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -628,7 +627,7 @@ const beginDeleteMethodOperationSpec: msRest.OperationSpec = { httpMethod: "DELETE", path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}", urlParameters: [ - Parameters.resourceGroupName, + Parameters.resourceGroupName0, Parameters.profileName, Parameters.subscriptionId ], @@ -655,6 +654,9 @@ const listNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], @@ -676,6 +678,9 @@ const listByResourceGroupNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], @@ -697,6 +702,9 @@ const listResourceUsageNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/resourceUsageOperations.ts b/sdk/cdn/arm-cdn/src/operations/resourceUsageOperations.ts index a8af3311c17b..d801d249f9e6 100644 --- a/sdk/cdn/arm-cdn/src/operations/resourceUsageOperations.ts +++ b/sdk/cdn/arm-cdn/src/operations/resourceUsageOperations.ts @@ -1,7 +1,6 @@ /* - * Copyright (c) Microsoft Corporation. All rights reserved. - * Licensed under the MIT License. See License.txt in the project root for - * license information. + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. * * Code generated by Microsoft (R) AutoRest Code Generator. * Changes may cause incorrect behavior and will be lost if the code is @@ -111,6 +110,9 @@ const listNextOperationSpec: msRest.OperationSpec = { urlParameters: [ Parameters.nextPageLink ], + queryParameters: [ + Parameters.apiVersion + ], headerParameters: [ Parameters.acceptLanguage ], diff --git a/sdk/cdn/arm-cdn/src/operations/routes.ts b/sdk/cdn/arm-cdn/src/operations/routes.ts new file mode 100644 index 000000000000..b4e3523b95f9 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/routes.ts @@ -0,0 +1,436 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/routesMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a Routes. */ +export class Routes { + private readonly client: CdnManagementClientContext; + + /** + * Create a Routes. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists all of the existing origins within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param callback The callback + */ + listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param options The optional parameters + * @param callback The callback + */ + listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByEndpoint(resourceGroupName: string, profileName: string, endpointName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + endpointName, + options + }, + listByEndpointOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing route with the specified route name under the specified subscription, resource + * group, profile, and AzureFrontDoor endpoint. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + endpointName, + routeName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new route with the specified route name under the specified subscription, resource + * group, profile, and AzureFrontDoor endpoint. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param route Route properties + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, route: Models.Route, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,profileName,endpointName,routeName,route,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing route with the specified route name under the specified subscription, + * resource group, profile, and AzureFrontDoor endpoint. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param routeUpdateProperties Route update properties + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, routeUpdateProperties: Models.RouteUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginUpdate(resourceGroupName,profileName,endpointName,routeName,routeUpdateProperties,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing route with the specified route name under the specified subscription, + * resource group, profile, and AzureFrontDoor endpoint. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,endpointName,routeName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates a new route with the specified route name under the specified subscription, resource + * group, profile, and AzureFrontDoor endpoint. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param route Route properties + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, route: Models.Route, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + routeName, + route, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing route with the specified route name under the specified subscription, + * resource group, profile, and AzureFrontDoor endpoint. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param routeUpdateProperties Route update properties + * @param [options] The optional parameters + * @returns Promise + */ + beginUpdate(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, routeUpdateProperties: Models.RouteUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + routeName, + routeUpdateProperties, + options + }, + beginUpdateOperationSpec, + options); + } + + /** + * Deletes an existing route with the specified route name under the specified subscription, + * resource group, profile, and AzureFrontDoor endpoint. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param endpointName Name of the endpoint under the profile which is unique globally. + * @param routeName Name of the routing rule. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, endpointName: string, routeName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + endpointName, + routeName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists all of the existing origins within a profile. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByEndpointNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByEndpointNext(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 + */ + listByEndpointNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByEndpointNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByEndpointNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByEndpointOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/routes", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RouteListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/routes/{routeName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.routeName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Route + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/routes/{routeName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.routeName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "route", + mapper: { + ...Mappers.Route, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Route + }, + 201: { + bodyMapper: Mappers.Route + }, + 202: { + bodyMapper: Mappers.Route + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/routes/{routeName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.routeName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "routeUpdateProperties", + mapper: { + ...Mappers.RouteUpdateParameters, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Route + }, + 202: { + bodyMapper: Mappers.Route + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/afdEndpoints/{endpointName}/routes/{routeName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.endpointName, + Parameters.routeName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByEndpointNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RouteListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/ruleSets.ts b/sdk/cdn/arm-cdn/src/operations/ruleSets.ts new file mode 100644 index 000000000000..40239b190472 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/ruleSets.ts @@ -0,0 +1,441 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/ruleSetsMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a RuleSets. */ +export class RuleSets { + private readonly client: CdnManagementClientContext; + + /** + * Create a RuleSets. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists existing AzureFrontDoor rule sets within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + listByProfileOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing AzureFrontDoor rule set with the specified rule set name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, ruleSetName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, ruleSetName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + ruleSetName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new rule set within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,profileName,ruleSetName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing AzureFrontDoor rule set with the specified rule set name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,ruleSetName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsage(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, ruleSetName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param options The optional parameters + * @param callback The callback + */ + listResourceUsage(resourceGroupName: string, profileName: string, ruleSetName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsage(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + ruleSetName, + options + }, + listResourceUsageOperationSpec, + callback) as Promise; + } + + /** + * Creates a new rule set within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + ruleSetName, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Deletes an existing AzureFrontDoor rule set with the specified rule set name under the specified + * subscription, resource group and profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile which is unique globally. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + ruleSetName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists existing AzureFrontDoor rule sets within a profile. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByProfileNext(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 + */ + listByProfileNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByProfileNextOperationSpec, + callback) as Promise; + } + + /** + * Checks the quota and actual usage of endpoints under the given CDN profile. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listResourceUsageNext(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 + */ + listResourceUsageNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listResourceUsageNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listResourceUsageNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByProfileOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RuleSetListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RuleSet + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listResourceUsageOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}/usages", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RuleSet + }, + 201: { + bodyMapper: Mappers.RuleSet + }, + 202: { + bodyMapper: Mappers.RuleSet + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByProfileNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RuleSetListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listResourceUsageNextOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UsagesListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/rules.ts b/sdk/cdn/arm-cdn/src/operations/rules.ts new file mode 100644 index 000000000000..b30e6a376e44 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/rules.ts @@ -0,0 +1,429 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/rulesMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a Rules. */ +export class Rules { + private readonly client: CdnManagementClientContext; + + /** + * Create a Rules. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists all of the existing delivery rules within a rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + listByRuleSet(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param callback The callback + */ + listByRuleSet(resourceGroupName: string, profileName: string, ruleSetName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param options The optional parameters + * @param callback The callback + */ + listByRuleSet(resourceGroupName: string, profileName: string, ruleSetName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByRuleSet(resourceGroupName: string, profileName: string, ruleSetName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + ruleSetName, + options + }, + listByRuleSetOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing delivery rule within a rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + ruleSetName, + ruleName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new delivery rule within the specified rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param rule The delivery rule properties. + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, rule: Models.Rule, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreate(resourceGroupName,profileName,ruleSetName,ruleName,rule,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing delivery rule within a rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param ruleUpdateProperties Delivery rule properties + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, ruleUpdateProperties: Models.RuleUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.beginUpdate(resourceGroupName,profileName,ruleSetName,ruleName,ruleUpdateProperties,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing delivery rule within a rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,ruleSetName,ruleName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates a new delivery rule within the specified rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param rule The delivery rule properties. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, rule: Models.Rule, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + ruleSetName, + ruleName, + rule, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing delivery rule within a rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param ruleUpdateProperties Delivery rule properties + * @param [options] The optional parameters + * @returns Promise + */ + beginUpdate(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, ruleUpdateProperties: Models.RuleUpdateParameters, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + ruleSetName, + ruleName, + ruleUpdateProperties, + options + }, + beginUpdateOperationSpec, + options); + } + + /** + * Deletes an existing delivery rule within a rule set. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param ruleSetName Name of the rule set under the profile. + * @param ruleName Name of the delivery rule which is unique within the endpoint. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, ruleSetName: string, ruleName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + ruleSetName, + ruleName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists all of the existing delivery rules within a rule set. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByRuleSetNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByRuleSetNext(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 + */ + listByRuleSetNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByRuleSetNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByRuleSetNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByRuleSetOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}/rules", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RuleListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}/rules/{ruleName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.ruleName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Rule + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}/rules/{ruleName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.ruleName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "rule", + mapper: { + ...Mappers.Rule, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Rule + }, + 201: { + bodyMapper: Mappers.Rule + }, + 202: { + bodyMapper: Mappers.Rule + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}/rules/{ruleName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.ruleName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "ruleUpdateProperties", + mapper: { + ...Mappers.RuleUpdateParameters, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Rule + }, + 202: { + bodyMapper: Mappers.Rule + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/ruleSets/{ruleSetName}/rules/{ruleName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.ruleSetName, + Parameters.ruleName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByRuleSetNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RuleListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/secrets.ts b/sdk/cdn/arm-cdn/src/operations/secrets.ts new file mode 100644 index 000000000000..08dbca771caf --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/secrets.ts @@ -0,0 +1,411 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/secretsMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a Secrets. */ +export class Secrets { + private readonly client: CdnManagementClientContext; + + /** + * Create a Secrets. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists existing AzureFrontDoor secrets. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + listByProfileOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing Secret within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, secretName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, secretName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, secretName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, secretName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + secretName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new Secret within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, secretName: string, options?: Models.SecretsCreateOptionalParams): Promise { + return this.beginCreate(resourceGroupName,profileName,secretName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing Secret within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + update(resourceGroupName: string, profileName: string, secretName: string, options?: Models.SecretsUpdateOptionalParams): Promise { + return this.beginUpdate(resourceGroupName,profileName,secretName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing Secret within profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, secretName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,secretName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates a new Secret within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, secretName: string, options?: Models.SecretsBeginCreateOptionalParams): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + secretName, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing Secret within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginUpdate(resourceGroupName: string, profileName: string, secretName: string, options?: Models.SecretsBeginUpdateOptionalParams): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + secretName, + options + }, + beginUpdateOperationSpec, + options); + } + + /** + * Deletes an existing Secret within profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param secretName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, secretName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + secretName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists existing AzureFrontDoor secrets. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByProfileNext(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 + */ + listByProfileNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByProfileNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByProfileOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/secrets", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SecretListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/secrets/{secretName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.secretName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Secret + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/secrets/{secretName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.secretName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + parameters: [ + "options", + "parameters" + ] + }, + mapper: { + ...Mappers.Secret, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Secret + }, + 201: { + bodyMapper: Mappers.Secret + }, + 202: { + bodyMapper: Mappers.Secret + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/secrets/{secretName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.secretName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + parameters: [ + "options", + "parameters" + ] + }, + mapper: { + ...Mappers.SecretProperties, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Secret + }, + 202: { + bodyMapper: Mappers.Secret + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/secrets/{secretName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.secretName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByProfileNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SecretListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/securityPolicies.ts b/sdk/cdn/arm-cdn/src/operations/securityPolicies.ts new file mode 100644 index 000000000000..b7d2c38280a3 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/securityPolicies.ts @@ -0,0 +1,411 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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 msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/securityPoliciesMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a SecurityPolicies. */ +export class SecurityPolicies { + private readonly client: CdnManagementClientContext; + + /** + * Create a SecurityPolicies. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Lists security policies associated with the profile + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param options The optional parameters + * @param callback The callback + */ + listByProfile(resourceGroupName: string, profileName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfile(resourceGroupName: string, profileName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + options + }, + listByProfileOperationSpec, + callback) as Promise; + } + + /** + * Gets an existing security policy within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the security policy under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + get(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the security policy under the profile. + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, securityPolicyName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the security policy under the profile. + * @param options The optional parameters + * @param callback The callback + */ + get(resourceGroupName: string, profileName: string, securityPolicyName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + profileName, + securityPolicyName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new security policy within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the security policy under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + create(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: Models.SecurityPoliciesCreateOptionalParams): Promise { + return this.beginCreate(resourceGroupName,profileName,securityPolicyName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Updates an existing Secret within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the security policy under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + patch(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: Models.SecurityPoliciesPatchOptionalParams): Promise { + return this.beginPatch(resourceGroupName,profileName,securityPolicyName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes an existing security policy within profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(resourceGroupName,profileName,securityPolicyName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates a new security policy within the specified profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the security policy under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreate(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: Models.SecurityPoliciesBeginCreateOptionalParams): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + securityPolicyName, + options + }, + beginCreateOperationSpec, + options); + } + + /** + * Updates an existing Secret within a profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the security policy under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginPatch(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: Models.SecurityPoliciesBeginPatchOptionalParams): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + securityPolicyName, + options + }, + beginPatchOperationSpec, + options); + } + + /** + * Deletes an existing security policy within profile. + * @param resourceGroupName Name of the Resource group within the Azure subscription. + * @param profileName Name of the CDN profile which is unique within the resource group. + * @param securityPolicyName Name of the Secret under the profile. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(resourceGroupName: string, profileName: string, securityPolicyName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + resourceGroupName, + profileName, + securityPolicyName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists security policies associated with the profile + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByProfileNext(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 + */ + listByProfileNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByProfileNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByProfileNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByProfileOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/securityPolicies", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SecurityPolicyListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/securityPolicies/{securityPolicyName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.securityPolicyName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SecurityPolicy + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginCreateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/securityPolicies/{securityPolicyName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.securityPolicyName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + parameters: [ + "options", + "parameters" + ] + }, + mapper: { + ...Mappers.SecurityPolicy, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.SecurityPolicy + }, + 201: { + bodyMapper: Mappers.SecurityPolicy + }, + 202: { + bodyMapper: Mappers.SecurityPolicy + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginPatchOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/securityPolicies/{securityPolicyName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.securityPolicyName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + parameters: [ + "options", + "parameters" + ] + }, + mapper: { + ...Mappers.SecurityPolicyProperties, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.SecurityPolicy + }, + 202: { + bodyMapper: Mappers.SecurityPolicy + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/securityPolicies/{securityPolicyName}", + urlParameters: [ + Parameters.resourceGroupName0, + Parameters.profileName, + Parameters.securityPolicyName, + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; + +const listByProfileNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SecurityPolicyListResult + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +}; diff --git a/sdk/cdn/arm-cdn/src/operations/validate.ts b/sdk/cdn/arm-cdn/src/operations/validate.ts new file mode 100644 index 000000000000..ae5836e9b109 --- /dev/null +++ b/sdk/cdn/arm-cdn/src/operations/validate.ts @@ -0,0 +1,97 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * 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/validateMappers"; +import * as Parameters from "../models/parameters"; +import { CdnManagementClientContext } from "../cdnManagementClientContext"; + +/** Class representing a Validate. */ +export class Validate { + private readonly client: CdnManagementClientContext; + + /** + * Create a Validate. + * @param {CdnManagementClientContext} client Reference to the service client. + */ + constructor(client: CdnManagementClientContext) { + this.client = client; + } + + /** + * Validate a Secret in the profile. + * @param secretSource The secret source. + * @param secretType The secret type. Possible values include: 'UrlSigningKey', + * 'ManagedCertificate', 'CustomerCertificate' + * @param [options] The optional parameters + * @returns Promise + */ + secretMethod(secretSource: Models.ResourceReference, secretType: Models.ValidateSecretType, options?: msRest.RequestOptionsBase): Promise; + /** + * @param secretSource The secret source. + * @param secretType The secret type. Possible values include: 'UrlSigningKey', + * 'ManagedCertificate', 'CustomerCertificate' + * @param callback The callback + */ + secretMethod(secretSource: Models.ResourceReference, secretType: Models.ValidateSecretType, callback: msRest.ServiceCallback): void; + /** + * @param secretSource The secret source. + * @param secretType The secret type. Possible values include: 'UrlSigningKey', + * 'ManagedCertificate', 'CustomerCertificate' + * @param options The optional parameters + * @param callback The callback + */ + secretMethod(secretSource: Models.ResourceReference, secretType: Models.ValidateSecretType, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + secretMethod(secretSource: Models.ResourceReference, secretType: Models.ValidateSecretType, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + secretSource, + secretType, + options + }, + secretMethodOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const secretMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/providers/Microsoft.Cdn/validateSecret", + urlParameters: [ + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: { + secretSource: "secretSource", + secretType: "secretType" + }, + mapper: { + ...Mappers.ValidateSecretInput, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.ValidateSecretOutput + }, + default: { + bodyMapper: Mappers.AfdErrorResponse + } + }, + serializer +};