Endpoints - Validate Custom Domain
Validates the custom domain mapping to ensure it maps to the correct CDN endpoint in DNS.
POST https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cdn/profiles/{profileName}/endpoints/{endpointName}/validateCustomDomain?api-version=2025-04-15
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
endpoint
|
path | True |
string |
Name of the endpoint under the profile which is unique globally. |
profile
|
path | True |
string |
Name of the CDN profile which is unique within the resource group. |
resource
|
path | True |
string minLength: 1maxLength: 90 |
The name of the resource group. The name is case insensitive. |
subscription
|
path | True |
string (uuid) |
The ID of the target subscription. The value must be an UUID. |
api-version
|
query | True |
string minLength: 1 |
The API version to use for this operation. |
Request Body
Name | Required | Type | Description |
---|---|---|---|
hostName | True |
string |
The host name of the custom domain. Must be a domain name. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
OK. The request has succeeded. |
|
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
Endpoints_ValidateCustomDomain
Sample request
Sample response
{
"customDomainValidated": true,
"message": null,
"reason": null
}
Definitions
Name | Description |
---|---|
Error |
The resource management error additional info. |
Error |
The error detail. |
Error |
Error response |
Validate |
Input of the custom domain to be validated for DNS mapping. |
Validate |
Output of custom domain validation. |
ErrorAdditionalInfo
The resource management error additional info.
Name | Type | Description |
---|---|---|
info |
object |
The additional info. |
type |
string |
The additional info type. |
ErrorDetail
The error detail.
Name | Type | Description |
---|---|---|
additionalInfo |
The error additional info. |
|
code |
string |
The error code. |
details |
The error details. |
|
message |
string |
The error message. |
target |
string |
The error target. |
ErrorResponse
Error response
Name | Type | Description |
---|---|---|
error |
The error object. |
ValidateCustomDomainInput
Input of the custom domain to be validated for DNS mapping.
Name | Type | Description |
---|---|---|
hostName |
string |
The host name of the custom domain. Must be a domain name. |
ValidateCustomDomainOutput
Output of custom domain validation.
Name | Type | Description |
---|---|---|
customDomainValidated |
boolean |
Indicates whether the custom domain is valid or not. |
message |
string |
Error message describing why the custom domain is not valid. |
reason |
string |
The reason why the custom domain is not valid. |