Skip to content

[DNS] Document shadowed records and shadow metadata#31731

Draft
matildeopbravo wants to merge 3 commits into
productionfrom
matilde/shadowed-records-clarify
Draft

[DNS] Document shadowed records and shadow metadata#31731
matildeopbravo wants to merge 3 commits into
productionfrom
matilde/shadowed-records-clarify

Conversation

@matildeopbravo

@matildeopbravo matildeopbravo commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Summary

Adds a new DNS reference page documenting shadowed records and the shadow metadata API behavior.

The page explains what shadowed records are, covers glue and dead glue records, and documents the shadow metadata fields (shadowed_by, is_glue, dead_glue, shadowed_records_count) along with how to request them.

Documentation checklist

  • Is there a changelog entry (guidelines)? If you don't add one for something awesome and new (however small) — how will our customers find out? Changelogs are automatically posted to RSS feeds, the Discord, and X.
  • The change adheres to the documentation style guide.
  • If a larger change - such as adding a new page- an issue has been opened in relation to any incorrect or out of date information that this PR fixes.

@github-actions

Copy link
Copy Markdown
Contributor

This pull request requires reviews from CODEOWNERS as it changes files that match the following patterns:

Pattern Owners
/src/content/docs/dns/ @RebeccaTamachiro, @hannes-cf, @cloudflare/product-owners, @esomoza-cf, @fattouche, @xofyarg, @dklbreitling, @chreo, @svenr-cf, @kerolasa, @matildeopbravo, @vavrusa, @mworsley-cloudflare, @sebastiaanyn, @vendemiat, @Woutifier

@matildeopbravo matildeopbravo force-pushed the matilde/shadowed-records-clarify branch from 4975690 to ca9e9b5 Compare June 26, 2026 17:51
@ask-bonk ask-bonk Bot added documentation Documentation edits content:new Request for new/missing content triage Waiting for a docs team review. labels Jun 26, 2026

@ask-bonk ask-bonk Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: 5 style issues need fixing before merge. No build breakers.

Issues:

  • HIGH (line 28): ns1.externalprovider.com is not a reserved example domain and could resolve to a live origin. Replace with ns1.example.org.
  • MEDIUM (line 4): description exceeds the 160-character limit. Shorten to stay within the style guide range.
  • MEDIUM (line 9): H1 heading in body content duplicates the frontmatter title. Remove it to match other pages in this directory.
  • LOW (line 20): Directional language (below) and See should be Refer to.
  • LOW (lines 171, 180): Placeholders <ns-record-id> should be <NS_RECORD_ID> (uppercase, underscores) per non-API placeholder conventions.

Note: Consider adding products:\n - dns to frontmatter for consistency with sibling reference pages. The changelog checkbox is unchecked — if include_shadow_metadata is new API behavior, add a changelog entry.

---
title: Shadowed records
pcx_content_type: concept
description: Shadowed records are DNS records that exist in your zone but are never served because a subdomain delegation takes precedence. Learn how Cloudflare detects and annotates them.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shorten to meet the 160-character limit:

Suggested change
description: Shadowed records are DNS records that exist in your zone but are never served because a subdomain delegation takes precedence. Learn how Cloudflare detects and annotates them.
description: DNS records that exist in your zone but are never served because a subdomain delegation takes precedence. Learn how Cloudflare detects and annotates them.

order: 5
---

# Shadowed records

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove this H1 heading. The title frontmatter already renders as the page H1. Sibling reference pages in this directory do not include an H1 in body content.

Shadowed records are invisible to DNS resolvers. Consider this example:

```txt
sub.example.com NS ns1.externalprovider.com.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use a reserved example domain to avoid resolving to a live origin:

Suggested change
sub.example.com NS ns1.externalprovider.com.
sub.example.com NS ns1.example.org.

This metadata is exposed in two places: as fields on API responses (covering whether a record is shadowed, whether it serves a special role as glue, and how many records a delegation hides) and as warnings in the Cloudflare dashboard on record creation and in the DNS record list.

:::note
Shadow metadata is computed on demand at read time and is never stored. It is not returned unless you explicitly request it. See [Request shadow metadata](#request-shadow-metadata) below.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Avoid directional language. Use Refer to instead of See:

Suggested change
Shadow metadata is computed on demand at read time and is never stored. It is not returned unless you explicitly request it. See [Request shadow metadata](#request-shadow-metadata) below.
Shadow metadata is computed on demand at read time and is never stored. It is not returned unless you explicitly request it. Refer to [Request shadow metadata](#request-shadow-metadata).

"name": "ns1.sub.example.com",
"content": "192.0.2.1",
"meta": {
"shadowed_by": ["<ns-record-id>"],

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use uppercase placeholder format consistent with style guide conventions:

Suggested change
"shadowed_by": ["<ns-record-id>"],
"shadowed_by": ["<NS_RECORD_ID>"],

Comment thread src/content/docs/dns/manage-dns-records/reference/shadowed-records.mdx Outdated
@ask-bonk

ask-bonk Bot commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

I have completed the review of PR #31731. Here's a summary of what I did:

Labels applied: product:dns, documentation, content:new, triage

Review summary: I posted a review comment with 5 inline suggestions/comments. The PR introduces a well-structured DNS reference page for shadowed records and shadow metadata. The main issues I flagged are:

  • HIGH (line 28): ns1.externalprovider.com is not a reserved example domain and could resolve to a live origin.
  • MEDIUM (line 4): The description field exceeds the 160-character style guide limit.
  • MEDIUM (line 9): There is an H1 heading in the body content, which duplicates the frontmatter title and doesn't match other pages in the directory.
  • LOW (line 20): Directional language (below) and See should be Refer to.
  • LOW (lines 171, 180): Placeholders <ns-record-id> should use uppercase/underscore format (<NS_RECORD_ID>).

I also noted that the author should consider adding products: - dns for consistency, and check whether a changelog entry is needed for the new include_shadow_metadata API behavior documentation.

github run

matildeopbravo and others added 2 commits June 26, 2026 18:57
…ords.mdx

Co-authored-by: ask-bonk[bot] <249159057+ask-bonk[bot]@users.noreply.github.com>
Shorten description under the 160-char limit, add products frontmatter,
remove the duplicate H1, use a reserved example domain, fix the
remaining placeholder, and replace directional link text.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

content:new Request for new/missing content documentation Documentation edits product:dns Issues or PRs related to DNS size/m triage Waiting for a docs team review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.