Get-EntraDomainVerificationDnsRecord
Retrieve the domain verification DNS record for a domain.
Syntax
Get-EntraDomainVerificationDnsRecord
-Name <String>
[-Property <String[]>]
[<CommonParameters>]
Description
Gets the domain's verification records from the verificationDnsRecords
navigation property.
You can't use the domain with your Microsoft Entra ID tenant until you have successfully verified that you own the domain.
To verify the ownership of the domain, you need to first retrieve a set of domain verification records that you need to add to the zone file of the domain. This can be done through the domain registrar or DNS server configuration.
Root domains require verification. For example, contoso.com requires verification. If a root domain is verified, subdomains of the root domain are automatically verified. For example, subdomain.contoso.com is automatically be verified if contoso.com has been verified.
The work or school account needs to belong to at least the Domain Name Administrator or Global Reader Microsoft Entra role.
Examples
Example 1: Retrieve the domain verification DNS record
Connect-Entra -Scopes 'Domain.Read.All'
Get-EntraDomainVerificationDnsRecord -Name mail.contoso.com
Id IsOptional Label RecordType SupportedService Ttl
-- ---------- ----- ---------- ---------------- ---
aaaa0000-bb11-2222-33cc-444444dddddd False mail.contoso.com Txt Email 3600
bbbb1111-cc22-3333-44dd-555555eeeeee False mail.contoso.com Mx Email 3600
This example shows how to retrieve the Domain verification DNS records for a domain with the given name.
Parameters
-Name
The domain name for which the domain verification Domain Name System (DNS) records are to be retrieved.
Type: | System.String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Property
Specifies properties to be returned.
Type: | System.String[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Inputs
System.String
Outputs
System.Object