Custom Domains - Enable Custom Https

Enable https delivery of the custom domain.

POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/customDomains/{customDomainName}/enableCustomHttps?api-version=2017-10-12

URI Parameters

Name In Required Type Description
subscriptionId
path True
  • string

Azure Subscription ID.

resourceGroupName
path True
  • string

Name of the Resource group within the Azure subscription.

Regex pattern: ^[-\w\._\(\)]+$

profileName
path True
  • string

Name of the CDN profile which is unique within the resource group.

endpointName
path True
  • string

Name of the endpoint under the profile which is unique globally.

customDomainName
path True
  • string

Name of the custom domain within an endpoint.

api-version
query True
  • string

Version of the API to be used with the client request. Current version is 2017-04-02.

Request Body

The request body can be one of the following:

Name Description
CdnManagedHttpsParameters

Defines the certificate source parameters using CDN managed certificate for enabling SSL.

UserManagedHttpsParameters

Defines the certificate source parameters using user's keyvault certificate for enabling SSL.

CdnManagedHttpsParameters

Defines the certificate source parameters using CDN managed certificate for enabling SSL.

Name Required Type Description
certificateSource True string:
  • Cdn

Defines the source of the SSL certificate.

certificateSourceParameters True

Defines the certificate source parameters using CDN managed certificate for enabling SSL.

protocolType True

Defines the TLS extension protocol that is used for secure delivery.

UserManagedHttpsParameters

Defines the certificate source parameters using user's keyvault certificate for enabling SSL.

Name Required Type Description
certificateSource True string:
  • AzureKeyVault

Defines the source of the SSL certificate.

certificateSourceParameters True

Defines the certificate source parameters using user's keyvault certificate for enabling SSL.

protocolType True

Defines the TLS extension protocol that is used for secure delivery.

Responses

Name Type Description
200 OK

OK. The request has succeeded.

202 Accepted

Accepted and the operation will complete asynchronously.

Other Status Codes

CDN error response describing why the operation failed.

Security

azure_auth

Azure Active Directory OAuth2 Flow.

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

CustomDomains_EnableCustomHttpsUsingCDNManagedCertificate
CustomDomains_EnableCustomHttpsUsingYourOwnCertificate

CustomDomains_EnableCustomHttpsUsingCDNManagedCertificate

Sample Request

POST https://management.azure.com/subscriptions/subid/resourceGroups/RG/providers/Microsoft.Cdn/profiles/profile1/endpoints/endpoint1/customDomains/www-someDomain-net/enableCustomHttps?api-version=2017-10-12

Sample Response

{}

CustomDomains_EnableCustomHttpsUsingYourOwnCertificate

Sample Request

POST https://management.azure.com/subscriptions/subid/resourceGroups/RG/providers/Microsoft.Cdn/profiles/profile1/endpoints/endpoint1/customDomains/www-someDomain-net/enableCustomHttps?api-version=2017-10-12

Sample Response

{}

Definitions

CdnCertificateSourceParameters

Defines the parameters for using CDN managed certificate for securing custom domain.

CdnManagedHttpsParameters

Defines the certificate source parameters using CDN managed certificate for enabling SSL.

CertificateType

Type of certificate used

CustomDomain

Friendly domain name mapping to the endpoint hostname that the customer provides for branding purposes, e.g. www.contoso.com.

CustomDomainResourceState

Resource status of the custom domain.

CustomHttpsProvisioningState

Provisioning status of Custom Https of the custom domain.

CustomHttpsProvisioningSubstate

Provisioning substate shows the progress of custom HTTPS enabling/disabling process step by step.

DeleteRule

Describes the action that shall be taken when the certificate is removed from Key Vault.

ErrorResponse

Error response indicates CDN service is not able to process the incoming request. The reason is provided in the error message.

KeyVaultCertificateSourceParameters

Describes the parameters for using a user's KeyVault certificate for securing custom domain.

ProtocolType

Defines the TLS extension protocol that is used for secure delivery.

UpdateRule

Describes the action that shall be taken when the certificate is updated in Key Vault.

UserManagedHttpsParameters

Defines the certificate source parameters using user's keyvault certificate for enabling SSL.

CdnCertificateSourceParameters

Defines the parameters for using CDN managed certificate for securing custom domain.

Name Type Description
@odata.type enum:
  • #Microsoft.Azure.Cdn.Models.CdnCertificateSourceParameters
certificateType

Type of certificate used

CdnManagedHttpsParameters

Defines the certificate source parameters using CDN managed certificate for enabling SSL.

Name Type Description
certificateSource string:
  • Cdn

Defines the source of the SSL certificate.

certificateSourceParameters

Defines the certificate source parameters using CDN managed certificate for enabling SSL.

protocolType

Defines the TLS extension protocol that is used for secure delivery.

CertificateType

Type of certificate used

Name Type Description
Dedicated
  • string
Shared
  • string

CustomDomain

Friendly domain name mapping to the endpoint hostname that the customer provides for branding purposes, e.g. www.contoso.com.

Name Type Description
id
  • string

Resource ID.

name
  • string

Resource name.

properties.customHttpsProvisioningState

Provisioning status of Custom Https of the custom domain.

properties.customHttpsProvisioningSubstate

Provisioning substate shows the progress of custom HTTPS enabling/disabling process step by step.

properties.hostName
  • string

The host name of the custom domain. Must be a domain name.

properties.provisioningState
  • string

Provisioning status of the custom domain.

properties.resourceState

Resource status of the custom domain.

properties.validationData
  • string

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 in China.

type
  • string

Resource type.

CustomDomainResourceState

Resource status of the custom domain.

Name Type Description
Active
  • string
Creating
  • string
Deleting
  • string

CustomHttpsProvisioningState

Provisioning status of Custom Https of the custom domain.

Name Type Description
Disabled
  • string
Disabling
  • string
Enabled
  • string
Enabling
  • string
Failed
  • string

CustomHttpsProvisioningSubstate

Provisioning substate shows the progress of custom HTTPS enabling/disabling process step by step.

Name Type Description
CertificateDeleted
  • string
CertificateDeployed
  • string
DeletingCertificate
  • string
DeployingCertificate
  • string
DomainControlValidationRequestApproved
  • string
DomainControlValidationRequestRejected
  • string
DomainControlValidationRequestTimedOut
  • string
IssuingCertificate
  • string
PendingDomainControlValidationREquestApproval
  • string
SubmittingDomainControlValidationRequest
  • string

DeleteRule

Describes the action that shall be taken when the certificate is removed from Key Vault.

Name Type Description
NoAction
  • string

ErrorResponse

Error response indicates CDN service is not able to process the incoming request. The reason is provided in the error message.

Name Type Description
code
  • string

Error code.

message
  • string

Error message indicating why the operation failed.

KeyVaultCertificateSourceParameters

Describes the parameters for using a user's KeyVault certificate for securing custom domain.

Name Type Description
@odata.type enum:
  • #Microsoft.Azure.Cdn.Models.KeyVaultCertificateSourceParameters
deleteRule

Describes the action that shall be taken when the certificate is removed from Key Vault.

resourceGroupName
  • string

Resource group of the user's Key Vault containing the SSL certificate

secretName
  • string

The name of Key Vault Secret (representing the full certificate PFX) in Key Vault.

secretVersion
  • string

The version(GUID) of Key Vault Secret in Key Vault.

subscriptionId
  • string

Subscription Id of the user's Key Vault containing the SSL certificate

updateRule

Describes the action that shall be taken when the certificate is updated in Key Vault.

vaultName
  • string

The name of the user's Key Vault containing the SSL certificate

ProtocolType

Defines the TLS extension protocol that is used for secure delivery.

Name Type Description
IPBased
  • string
ServerNameIndication
  • string

UpdateRule

Describes the action that shall be taken when the certificate is updated in Key Vault.

Name Type Description
NoAction
  • string

UserManagedHttpsParameters

Defines the certificate source parameters using user's keyvault certificate for enabling SSL.

Name Type Description
certificateSource string:
  • AzureKeyVault

Defines the source of the SSL certificate.

certificateSourceParameters

Defines the certificate source parameters using user's keyvault certificate for enabling SSL.

protocolType

Defines the TLS extension protocol that is used for secure delivery.