I am using Pay-as-you-go subscription and i was using below Powershell command to create cdn profile.
New-AzCdnProfile -ProfileName "cdnprofileforcache" -ResourceGroupName "rg-cdn" -Sku "Premium_Verizon" -Location "Uk South" -ErrorAction Stop -Verbose
it returns me with very minimal information as error.
New-AzCdnProfile : Operation returned an invalid status code 'BadRequest' At line:1 char:1 + New-AzCdnProfile -ProfileName "cdnprofileforcache" -ResourceGroupName "rg-cdn" ... + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : CloseError: (:) [New-AzCdnProfile], ErrorResponseException + FullyQualifiedErrorId : Microsoft.Azure.Commands.Cdn.Profile.NewAzureRmCdnProfile
After i try multiple option with Powershell i was trying to execute same command with Azure CLI and i got bellow error. Which makes more scenes to me.
az : ERROR: (LocationNotAvailableForResourceType) The provided location 'uksouth' is not available for resource type 'Microsoft.Cdn/profiles'. List of available regions for the resource type is 'global,australiaeast,australiasouth east,brazilsouth,canadacentral,canadaeast,centralindia,centralus,eastasia,eastus,eastus2,japaneast,japanwest,northcentralus,northeurope,southcentralus,southindia,southeastasia,westeurope,westindia,westus,westcentralus'. At line:1 char:1
+ CategoryInfo : NotSpecified: (ERROR: (Locatio...westcentralus'.:String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
Then i try this Powershell command
Solutions :-
New-AzCdnProfile -ProfileName "cdnprofileforcache" -ResourceGroupName "rg-cdn" -Sku "Premium_Verizon" -Location Global -ErrorAction Stop -Verbose
Conclusion You need to use only those region where 'Microsoft.Cdn' provider does support. As of now (12/10/2021) Microsoft does support for only below regions. The below regions or location will change.