RazorDocs Search
API Reference

Models

Type

DocPageTypeBadgePresentation

Source

Presentation metadata for one normalized documentation page-type badge.

Property

Value

string Value { get; init; } Source

Gets the normalized machine-readable page-type value.

Property

Label

string Label { get; init; } Source

Gets the human-readable badge label.

Property

Variant

string Variant { get; init; } Source

Gets the badge variant suffix used by built-in RazorDocs CSS classes such as docs-page-badge--guide.

Type

DocMetadataPresentation

Source

Converts raw documentation metadata values into consistent UI-facing labels and badge variants.

Remarks

Use this helper from Razor views, search payload generation, or custom UI surfaces when you want the built-in RazorDocs page-type treatment to remain consistent across landing, detail, and search experiences.

Method

ResolvePageTypeBadge

DocPageTypeBadgePresentation? ResolvePageTypeBadge(string? pageType) Source

Resolves the built-in RazorDocs page-type badge presentation for a raw metadata value.

Parameters

  • pageTypeThe raw page-type metadata value, such as guide, api-reference, or release-note.

Returns

A normalized badge presentation when pageType is non-empty; otherwise, null. Release aliases such as release-note and release-notes resolve to the canonical release badge value. Unknown page types fall back to a neutral badge with a title-cased label.

Method

NormalizeToken

string? NormalizeToken(string? value) Source

Normalizes a raw metadata token into a lowercase dash-delimited value.

Parameters

  • valueRaw metadata token that may contain whitespace, underscores, dashes, or line breaks.

Returns

A normalized token, or null when value is null, whitespace, or produces no non-delimiter segments after trimming and splitting.

Remarks

RazorDocs trims the input, splits on spaces, tabs, carriage returns, line feeds, underscores, and hyphens, removes empty segments, lowercases each remaining segment, and rejoins them with -.

Type

DocMetadata

Source

Structured metadata that can drive navigation, breadcrumbs, related links, and search without re-parsing source content.

Property

Title

string? Title { get; init; } Source

Gets the resolved display title for the documentation node.

Property

Summary

string? Summary { get; init; } Source

Gets a short summary describing the documentation node.

Property

SummaryIsDerived

bool? SummaryIsDerived { get; init; } Source

Gets a value indicating whether Summary was derived from page content instead of authored explicitly.

Property

PageType

string? PageType { get; init; } Source

Gets the page type, such as guide, example, api-reference, or troubleshooting.

Property

Audience

string? Audience { get; init; } Source

Gets the intended audience for the page.

Property

Component

string? Component { get; init; } Source

Gets the product component associated with the page.

Property

Aliases

IReadOnlyList<string>? Aliases { get; init; } Source

Gets alternate terms that should resolve to this page in search.

Property

RedirectAliases

IReadOnlyList<string>? RedirectAliases { get; init; } Source

Gets alternate route aliases that should redirect to the canonical page when redirect support is enabled.

Property

Keywords

IReadOnlyList<string>? Keywords { get; init; } Source

Gets search keywords associated with the page.

Property

Status

string? Status { get; init; } Source

Gets the content lifecycle status for the page.

Property

NavGroup

string? NavGroup { get; init; } Source

Gets the navigation group used by public docs navigation.

Property

Order

int? Order { get; init; } Source

Gets the relative ordering value within a navigation group.

Property

SequenceKey

string? SequenceKey { get; init; } Source

Gets the explicit sequence identifier used to connect pages into one proof path.

Remarks

RazorDocs does not infer sequence membership from folders or filenames in this slice. Pages participate in next/previous wayfinding only when authors opt them into the same SequenceKey and assign comparable Order values.

Property

SectionLanding

bool? SectionLanding { get; init; } Source

Gets a value indicating whether the page is the authored landing doc for its public section.

Property

HideFromPublicNav

bool? HideFromPublicNav { get; init; } Source

Gets a value indicating whether the page should be hidden from public navigation.

Property

HideFromSearch

bool? HideFromSearch { get; init; } Source

Gets a value indicating whether the page should be hidden from search.

Property

RelatedPages

IReadOnlyList<string>? RelatedPages { get; init; } Source

Gets related page identifiers or titles.

Property

CanonicalSlug

string? CanonicalSlug { get; init; } Source

Gets the preferred canonical slug for the page.

Property

Breadcrumbs

IReadOnlyList<string>? Breadcrumbs { get; init; } Source

Gets optional human-readable breadcrumb labels for the page.

Property

FeaturedPageGroups

IReadOnlyList<DocFeaturedPageGroupDefinition>? FeaturedPageGroups { get; init; } Source

Gets optional landing-page curation groups authored with the documentation page.

Remarks

RazorDocs parses this metadata on any page so the contract stays page-agnostic. Authors can supply groups either inline in Markdown front matter or through a paired sidecar such as README.md.yml. The built-in docs landing consumes the repository-root README.md groups, and section landing docs consume their own groups for reader-intent next steps.

Property

Trust

DocTrustMetadata? Trust { get; init; } Source

Gets optional trust and provenance metadata rendered near the top of the page.

Remarks

This nested object is designed for release notes, upgrade policies, changelogs, and similar pages that need to communicate current status, adoption safety, and archival provenance without custom view logic.

Property

Contributor

DocContributorMetadata? Contributor { get; init; } Source

Gets optional contributor provenance metadata for page-level source, edit, and freshness control.

Property

BreadcrumbsMatchPathTargets

bool? BreadcrumbsMatchPathTargets { get; init; } Source

Gets a value indicating whether authored breadcrumb labels align with the path-derived breadcrumb targets that RazorDocs can safely reuse for rendering.

Type

DocOutlineItem

Source

Represents one navigable heading captured while harvesting a documentation page.

Property

Title

string Title { get; init; } Source

Gets the heading text shown in the page-local outline and search metadata.

Property

Id

string Id { get; init; } Source

Gets the HTML fragment identifier that anchors this outline item within the page.

Property

Level

int Level { get; init; } Source

Gets the normalized heading level for this entry.

Type

DocTrustMetadata

Source

Structured trust and provenance metadata for a documentation page.

Property

Status

string? Status { get; init; } Source

Gets the compact top-level state shown in the trust bar, such as Unreleased or Pre-1.0 policy.

Property

Summary

string? Summary { get; init; } Source

Gets the short trust statement that explains what the current status means for readers.

Property

Freshness

string? Freshness { get; init; } Source

Gets the freshness statement that explains how current or provisional the page is.

Property

ChangeScope

string? ChangeScope { get; init; } Source

Gets the statement describing which product surfaces or artifacts this page covers.

Property

Archive

string? Archive { get; init; } Source

Gets the archival or long-term home statement for the page contents.

Property

Sources

IReadOnlyList<string>? Sources { get; init; } Source

Gets optional provenance notes or upstream sources that support the page.

Type

DocContributorMetadata

Source

Page-level contributor provenance metadata used to override or suppress source, edit, and freshness evidence.

Method

Merge

DocContributorMetadata? Merge(DocContributorMetadata? primary, DocContributorMetadata? fallback) Source

Merges contributor metadata by preferring authored primary values and filling missing values from fallback metadata.

Remarks

Precedence rules:
  • HideContributorInfo uses nullable-boolean precedence, so explicit false is preserved.
  • SourcePathOverride, SourceUrlOverride, and EditUrlOverride prefer the first non-blank string; whitespace-only values are treated as missing.
  • LastUpdatedOverride uses null coalescing and therefore keeps the primary timestamp when present.
Pitfalls:
  • Setting a string override to the empty string does not clear a fallback value; it falls back instead.
  • Callers that need to suppress inherited contributor rendering should use HideContributorInfo instead of relying on blank string overrides.
Property

HideContributorInfo

bool? HideContributorInfo { get; init; } Source

Gets a value indicating whether contributor provenance should be hidden for the page even when automatic evidence exists.

Property

SourcePathOverride

string? SourcePathOverride { get; init; } Source

Gets an optional repository-relative source-path override used for source links, edit links, and git freshness resolution. Rooted paths and traversal segments are rejected.

Property

SourceUrlOverride

string? SourceUrlOverride { get; init; } Source

Gets an optional explicit source URL override. Only absolute HTTP(S) URLs and root-relative paths are accepted.

Property

EditUrlOverride

string? EditUrlOverride { get; init; } Source

Gets an optional explicit edit URL override. Only absolute HTTP(S) URLs and root-relative paths are accepted.

Property

LastUpdatedOverride

DateTimeOffset? LastUpdatedOverride { get; init; } Source

Gets an optional exact timestamp override for contributor freshness.

Type

DocSymbolSourceProvenance

Source

Identifies the source declaration that produced one rendered C# API documentation symbol.

Property

AnchorId

string AnchorId { get; init; } Source

Gets the rendered HTML anchor ID for the generated API symbol.

Property

SourcePath

string SourcePath { get; init; } Source

Gets the repository-relative source file path that contains the documented declaration.

Property

StartLine

int StartLine { get; init; } Source

Gets the 1-based source declaration line.

Type

DocNode

Source

Represents a documentation node within the repository.

Parameters

  • TitleThe display title of the document.
  • PathThe relative path to the documentation source.
  • ContentThe rendered HTML content of the documentation.
  • ParentPathThe optional parent path for hierarchical organization.
  • IsDirectoryIndicates if this node represents a directory container.
  • CanonicalPathThe browser-facing docs route path used for linking and lookup.
  • MetadataStructured metadata associated with the documentation node.
  • OutlineStructured in-page outline entries captured during harvesting.
  • SymbolSourceProvenanceOptional source declarations keyed by rendered C# API symbol anchor IDs.
Type

DocHarvestHealthSnapshot

Source

Captures the structured health of one RazorDocs harvest snapshot.

Parameters

  • StatusOverall health rollup for the snapshot.
  • GeneratedUtcUTC timestamp when the snapshot was generated.
  • RepositoryRootRepository root passed to configured harvesters. Treat this as server-only operational data because it can contain sensitive or environment-specific filesystem paths; redact or omit it before sending snapshots to clients.
  • TotalHarvestersNumber of harvesters configured for the snapshot.
  • SuccessfulHarvestersNumber of harvesters that completed with either docs or a valid empty result.
  • FailedHarvestersNumber of harvesters that failed, timed out, or canceled.
  • TotalDocsNumber of documentation nodes published by the final cached docs snapshot.
  • HarvestersPer-harvester health entries. Never null in RazorDocs-created snapshots.
  • DiagnosticsStructured diagnostics for failed, degraded, or noteworthy states. Never null in RazorDocs-created snapshots.

Remarks

RazorDocs-created snapshots retain non-null Harvesters and Diagnostics collections for safe server-side inspection, but callers that serialize this record into client-visible payloads must sanitize RepositoryRoot first.

Type

DocHarvesterHealth

Source

Captures one configured harvester's status inside a RazorDocs harvest snapshot.

Parameters

  • HarvesterTypeConcrete harvester type name used in logs and diagnostics.
  • StatusHarvester-level health status.
  • DocCountNumber of documentation nodes returned by the harvester before RazorDocs post-processing.
  • DiagnosticDiagnostic explaining a failed, timed-out, or canceled harvester; usually null for non-failure outcomes.
Type

DocHarvestDiagnostic

Source

Describes one structured RazorDocs harvest health diagnostic.

Parameters

  • CodeStable diagnostic code suitable for tests, logs, documentation, and host UI branching.
  • SeverityDiagnostic severity.
  • HarvesterTypeConcrete harvester type when the diagnostic belongs to one harvester, or null for aggregate diagnostics.
  • ProblemOperator-facing summary of what went wrong.
  • CauseExplanation of why RazorDocs could not safely treat the harvest as fully healthy.
  • FixSuggested operator or docs-author action that resolves the problem.
Type

DocHarvestDiagnosticCodes

Source

Defines the stable diagnostic codes emitted by RazorDocs harvest health snapshots.

Remarks

Use these constants when testing or branching on DocHarvestDiagnostic.Code values. The string values are public compatibility contracts and must not be changed once released.

Type

DocSectionSnapshot

Source

Represents one normalized public-section snapshot derived from the harvested docs corpus.

Property

Section

DocPublicSection Section { get; init; } Source

Gets the typed public section identifier.

Property

Label

string Label { get; init; } Source

Gets the canonical display label for the section.

Property

Slug

string Slug { get; init; } Source

Gets the stable route slug for the section.

Property

LandingDoc

DocNode? LandingDoc { get; init; } Source

Gets the optional authored landing doc that represents the section.

Property

VisiblePages

IReadOnlyList<DocNode> VisiblePages { get; init; } Source

Gets the public pages that belong to the section, ordered for display.

Type

DocFeaturedPageGroupDefinition

Source

Defines one authored reader-intent group for a docs landing surface.

Property

Intent

string? Intent { get; init; } Source

Gets the stable reader-intent identifier for the group.

Remarks

Authors may omit this value when Label is present. RazorDocs derives a normalized intent from the label during metadata parsing so downstream resolvers can still identify the group consistently.

Property

Label

string? Label { get; init; } Source

Gets the reader-facing group heading.

Remarks

Authors may omit this value when Intent is present. RazorDocs converts the intent into a title-cased label during metadata parsing so the landing can still render a useful heading.

Property

Summary

string? Summary { get; init; } Source

Gets optional copy that explains when a reader should choose the group.

Property

Order

int? Order { get; init; } Source

Gets the relative display order for the group.

Property

Pages

IReadOnlyList<DocFeaturedPageDefinition> Pages { get; init; } Source

Gets the featured destination pages in this group.

Property

SourceFieldPath

string? SourceFieldPath { get; init; } Source

Gets the parser-populated metadata field path for group-level diagnostics.

Remarks

This internal value is for diagnostics and source attribution only. Authored metadata and consumers should not depend on it as stable content because the parser path format may change.

Type

DocFeaturedPageDefinition

Source

Defines one authored featured-page entry for a docs landing surface.

Property

Question

string? Question { get; init; } Source

Gets the reader-facing evaluator question or label for the card.

Remarks

When this value is omitted on the built-in docs landing, RazorDocs falls back to the resolved destination page title so the card still renders with a sensible label.

Property

Path

string? Path { get; init; } Source

Gets the source or canonical path of the destination page to feature.

Remarks

RazorDocs matches both source paths and canonical browser paths. Path separators are normalized during resolution so authored forward-slash and backslash forms point to the same destination.

Property

SupportingCopy

string? SupportingCopy { get; init; } Source

Gets optional landing-only supporting copy shown instead of destination summary text.

Property

Order

int? Order { get; init; } Source

Gets the relative display order for the featured entry.

Property

SourceFieldPath

string? SourceFieldPath { get; init; } Source

Gets the parser-populated metadata field path for page-level diagnostics.

Remarks

This internal value is for diagnostics and source attribution only. Authored metadata and consumers should not depend on it as stable content because the parser path format may change.

Type

DocLandingViewModel

Source

View model for the docs landing page.

Property

Heading

string Heading { get; init; } Source

Gets the hero heading shown on the docs landing.

Property

Description

string Description { get; init; } Source

Gets the supporting description shown under the hero heading.

Property

LandingDoc

DocNode? LandingDoc { get; init; } Source

Gets the repository-root landing document when one was harvested.

Property

StartHereHref

string? StartHereHref { get; init; } Source

Gets the href for the section-level Start Here route when that section exists in the current public docs corpus.

Property

VisibleDocs

IReadOnlyList<DocNode> VisibleDocs { get; init; } Source

Gets the visible documentation nodes used by the neutral fallback landing state.

Property

FeaturedPageGroups

IReadOnlyList<DocLandingFeaturedPageGroupViewModel> FeaturedPageGroups { get; init; } Source

Gets the resolved proof-path groups for the landing experience.

Property

SecondarySections

IReadOnlyList<DocHomeSectionViewModel> SecondarySections { get; init; } Source

Gets the secondary section summaries shown under the primary Start Here route.

Property

HasFeaturedPages

bool HasFeaturedPages { get; } Source

Gets a value indicating whether the landing should render a proof-path lead section.

Type

DocLandingFeaturedPageGroupViewModel

Source

View model for one resolved reader-intent group on a docs landing page.

Remarks

Intent and Label are normalized by the featured-page resolver before rendering: authored whitespace is trimmed, missing labels fall back to the resolved intent, and both values are non-null. Summary contains optional group copy and may be null. Pages contains the resolved DocLandingFeaturedPageViewModel rows produced by the resolver after it matches authored destinations to visible docs. Empty Pages lists are treated as no featured pages and are suppressed by DocLandingViewModel.HasFeaturedPages, DocDetailsViewModel.HasFeaturedPages, and the RazorDocs views. Pitfalls: callers should not rely on an empty Pages list being rendered, and should expect Intent, Label, Summary, and Pages to reflect resolver output rather than raw authored front matter.

Property

Intent

string Intent { get; init; } Source

Gets the stable reader-intent identifier for the group.

Property

Label

string Label { get; init; } Source

Gets the reader-facing group label.

Property

Summary

string? Summary { get; init; } Source

Gets optional copy that explains when to choose this group.

Property

Pages

IReadOnlyList<DocLandingFeaturedPageViewModel> Pages { get; init; } Source

Gets the resolved featured-page rows in this group.

Type

DocLandingFeaturedPageViewModel

Source

View model for one resolved featured card on the docs landing page.

Property

Question

string Question { get; init; } Source

Gets the evaluator question or label shown on the card.

Property

Title

string Title { get; init; } Source

Gets the destination page title shown on the card.

Property

Href

string Href { get; init; } Source

Gets the browser-facing link to the destination page.

Property

PageType

string? PageType { get; init; } Source

Gets the destination page type, such as guide, example, or api-reference.

Property

PageTypeBadge

DocPageTypeBadgePresentation? PageTypeBadge { get; init; } Source

Gets the normalized badge presentation for PageType when RazorDocs can render one.

Property

SupportingText

string? SupportingText { get; init; } Source

Gets the supporting body copy shown on the card.

Type

DocHomeSectionViewModel

Source

View model describing one secondary public-section summary on the docs home.

Property

Section

DocPublicSection Section { get; init; } Source

Gets the typed public section represented by the summary.

Property

Label

string Label { get; init; } Source

Gets the section label shown to the reader.

Property

Slug

string Slug { get; init; } Source

Gets the stable route slug for the section.

Property

Href

string Href { get; init; } Source

Gets the route that enters the section.

Property

Purpose

string Purpose { get; init; } Source

Gets the one-sentence utility copy that explains what the reader can do in the section.

Property

KeyRoutes

IReadOnlyList<DocSectionLinkViewModel> KeyRoutes { get; init; } Source

Gets the key routes surfaced for the section on the docs home.

Type

DocBreadcrumbViewModel

Source

View model for a section-scoped or doc-scoped breadcrumb item.

Property

Label

string Label { get; init; } Source

Gets the breadcrumb label shown to the reader.

Property

Href

string? Href { get; init; } Source

Gets the optional target href for the breadcrumb.

Type

DocSectionLinkViewModel

Source

View model for one section list or sidebar link.

Property

Title

string Title { get; init; } Source

Gets the displayed link title.

Property

Href

string Href { get; init; } Source

Gets the destination href.

Property

Summary

string? Summary { get; init; } Source

Gets optional utility copy shown with the link.

Property

Eyebrow

string? Eyebrow { get; init; } Source

Gets optional short eyebrow text shown above the link title.

Property

PageTypeBadge

DocPageTypeBadgePresentation? PageTypeBadge { get; init; } Source

Gets the normalized page-type badge for the destination when one is available.

Property

Children

IReadOnlyList<DocSectionLinkViewModel> Children { get; init; } Source

Gets nested child links shown under the current link.

Property

UseAnchorNavigation

bool UseAnchorNavigation { get; init; } Source

Gets a value indicating whether the link should use docs anchor navigation semantics.

Property

IsCurrent

bool IsCurrent { get; init; } Source

Gets a value indicating whether this link represents the current page.

Type

DocSectionGroupViewModel

Source

View model for one grouped set of section links.

Property

Title

string? Title { get; init; } Source

Gets the optional group heading shown above the link list.

Type

DocPageLinkViewModel

Source

View model for one resolved documentation link shown in related or sequence wayfinding.

Property

Title

string Title { get; init; } Source

Gets the destination page title.

Property

Href

string Href { get; init; } Source

Gets the browser-facing destination URL.

Property

Summary

string? Summary { get; init; } Source

Gets optional supporting text for the destination.

Property

PageTypeBadge

DocPageTypeBadgePresentation? PageTypeBadge { get; init; } Source

Gets the normalized page type badge metadata for the destination when available.

Type

DocSidebarViewModel

Source

View model for the sidebar navigation shell.

Property

Sections

IReadOnlyList<DocSidebarSectionViewModel> Sections { get; init; } Source

Gets the sections shown in the sidebar.

Property

HarvestHealth

DocSidebarHarvestHealthViewModel? HarvestHealth { get; init; } Source

Gets the harvest health sidebar entry when the current host should show health chrome.

Type

DocSidebarHarvestHealthViewModel

Source

View model for the RazorDocs harvest health sidebar entry.

Property

Status

string Status { get; init; } Source

Gets the aggregate harvest status label.

Property

Ok

bool Ok { get; init; } Source

Gets a value indicating whether the status should pass local or CI verification.

Property

Href

string? Href { get; init; } Source

Gets the app-relative health page route when health routes are exposed; otherwise null for status-only chrome.

Type

DocSidebarSectionViewModel

Source

View model for one public section in the sidebar.

Property

Section

DocPublicSection Section { get; init; } Source

Gets the typed section represented by the sidebar entry.

Property

Label

string Label { get; init; } Source

Gets the section label shown in the sidebar.

Property

Slug

string Slug { get; init; } Source

Gets the stable section slug.

Property

Href

string Href { get; init; } Source

Gets the section route href.

Property

IsActive

bool IsActive { get; init; } Source

Gets a value indicating whether the section owns the current page context.

Property

IsExpanded

bool IsExpanded { get; init; } Source

Gets a value indicating whether the section should render expanded by default.

Property

Groups

IReadOnlyList<DocSectionGroupViewModel> Groups { get; init; } Source

Gets the grouped links rendered when the section is expanded.

Type

DocSectionPageViewModel

Source

View model for the grouped-section fallback and unavailable section surfaces.

Property

Section

DocPublicSection? Section { get; init; } Source

Gets the typed section when the route resolved to a known built-in section.

Property

Heading

string Heading { get; init; } Source

Gets the section label or unavailable-page heading.

Property

Description

string Description { get; init; } Source

Gets the primary explanatory copy for the page.

Property

DocsHomeHref

string DocsHomeHref { get; init; } Source

Gets the docs home route.

Property

StartHereHref

string? StartHereHref { get; init; } Source

Gets the href for the section-level Start Here route when that section exists in the current public docs corpus.

Property

IsUnavailable

bool IsUnavailable { get; init; } Source

Gets a value indicating whether the route resolved to an unavailable section surface.

Property

AvailabilityMessage

string? AvailabilityMessage { get; init; } Source

Gets the explanatory copy shown when the section is unavailable.

Property

IsSparse

bool IsSparse { get; init; } Source

Gets a value indicating whether the fallback section is intentionally sparse.

Property

KeyRoutes

IReadOnlyList<DocSectionLinkViewModel> KeyRoutes { get; init; } Source

Gets the key routes surfaced for a sparse section fallback.

Property

Groups

IReadOnlyList<DocSectionGroupViewModel> Groups { get; init; } Source

Gets the grouped page lists shown for the section.

Type

DocDetailsViewModel

Source

View model for a rendered documentation details page.

Property

Document

DocNode Document { get; init; } Source

Gets the underlying documentation node.

Property

Outline

IReadOnlyList<DocOutlineItem> Outline { get; init; } Source

Gets the in-page outline entries for the current document.

Property

PreviousPage

DocPageLinkViewModel? PreviousPage { get; init; } Source

Gets the previous page within the current authored sequence, when one exists.

Property

NextPage

DocPageLinkViewModel? NextPage { get; init; } Source

Gets the next page within the current authored sequence, when one exists.

Property

RelatedPages

IReadOnlyList<DocPageLinkViewModel> RelatedPages { get; init; } Source

Gets the authored related pages that resolved successfully.

Property

ContributorProvenance

DocContributorProvenanceViewModel? ContributorProvenance { get; init; } Source

Gets the contributor provenance evidence resolved for the current page.

Property

Title

string Title { get; init; } Source

Gets the resolved display title for the page.

Property

Summary

string? Summary { get; init; } Source

Gets the authored summary that should be rendered under the title when available.

Property

ShowSummary

bool ShowSummary { get; init; } Source

Gets a value indicating whether Summary should be rendered.

Property

IsCSharpApiDoc

bool IsCSharpApiDoc { get; init; } Source

Gets a value indicating whether the page is a C# API reference document.

Property

IsApiSurfaceDoc

bool IsApiSurfaceDoc { get; init; } Source

Gets a value indicating whether the page should use the API reference reading surface.

Remarks

This covers non-Markdown generated documents and Markdown documents explicitly marked with API-oriented metadata, while IsCSharpApiDoc remains scoped to C# generated page chrome decisions.

Property

PageTypeBadge

DocPageTypeBadgePresentation? PageTypeBadge { get; init; } Source

Gets the normalized page-type badge presentation for the current page when available.

Property

Component

string? Component { get; init; } Source

Gets the explicit component metadata shown with the page when available.

Property

Audience

string? Audience { get; init; } Source

Gets the explicit audience metadata shown with the page when available.

Property

Breadcrumbs

IReadOnlyList<DocBreadcrumbViewModel> Breadcrumbs { get; init; } Source

Gets the breadcrumb trail used by the page.

Property

PublicSection

DocPublicSection? PublicSection { get; init; } Source

Gets the current public section when the page belongs to a public docs section.

Property

PublicSectionLabel

string? PublicSectionLabel { get; init; } Source

Gets the current public-section label when one exists.

Property

PublicSectionHref

string? PublicSectionHref { get; init; } Source

Gets the current public-section route href when one exists.

Property

PublicSectionPurpose

string? PublicSectionPurpose { get; init; } Source

Gets the current public-section utility sentence when one exists.

Property

TrustMigrationUsesTurbo

bool TrustMigrationUsesTurbo { get; init; } Source

Gets a value indicating whether the trust-bar migration link should stay inside the docs content frame.

Remarks

This is resolved from the harvested docs corpus rather than inferred from the raw href alone so root-mounted docs surfaces can still treat canonical plain .html docs routes as docs-local without misclassifying unrelated site pages.

Property

ContributorSourceUsesTurbo

bool ContributorSourceUsesTurbo { get; init; } Source

Gets a value indicating whether the contributor source link should stay inside the docs content frame.

Remarks

This is resolved from the harvested docs corpus rather than inferred from the raw href alone so mounted or root-hosted docs surfaces can keep local provenance links inside the docs shell without trapping unrelated app routes.

Property

ContributorEditUsesTurbo

bool ContributorEditUsesTurbo { get; init; } Source

Gets a value indicating whether the contributor edit link should stay inside the docs content frame.

Remarks

This follows the same docs-local resolution contract as ContributorSourceUsesTurbo so preview, versioned, and root-mounted docs surfaces all make the same frame-targeting decision.

Property

IsSectionLanding

bool IsSectionLanding { get; init; } Source

Gets a value indicating whether the current document is a section landing doc.

Property

FeaturedPageGroups

IReadOnlyList<DocLandingFeaturedPageGroupViewModel> FeaturedPageGroups { get; init; } Source

Gets the curated next-step groups shown by a section landing doc.

Property

HasFeaturedPages

bool HasFeaturedPages { get; } Source

Gets a value indicating whether any curated section-landing group has visible next-step pages.

Property

SectionGroups

IReadOnlyList<DocSectionGroupViewModel> SectionGroups { get; init; } Source

Gets the grouped In this section lists shown by a section landing doc.

Property

HasOutline

bool HasOutline { get; } Source

Gets a value indicating whether the page has an in-page outline to render.

Property

HasWayfinding

bool HasWayfinding { get; } Source

Gets a value indicating whether the page has any sequence or related-page wayfinding links to render.

Type

DocContributorProvenanceViewModel

Source

View model describing the contributor provenance evidence rendered near the top of a details page.

Property

Label

string Label { get; init; } Source

Gets the reader-facing provenance strip label.

Property

SourceHref

string? SourceHref { get; init; } Source

Gets the browser-facing source URL when one exists.

Property

EditHref

string? EditHref { get; init; } Source

Gets the browser-facing edit URL when one exists.

Property

LastUpdatedUtc

DateTimeOffset? LastUpdatedUtc { get; init; } Source

Gets the exact UTC timestamp used for contributor freshness when one exists.

Type

IDocHarvester

Source

Interface for harvesting documentation from various sources.

Method

HarvestAsync

Task<IReadOnlyList<DocNode>> HarvestAsync(string rootPath, CancellationToken cancellationToken = default) Source

Asynchronously scans the specified root path and returns a collection of documentation nodes harvested from sources under that path.

Parameters

  • rootPathThe filesystem root path to scan for documentation sources.
  • cancellationTokenAn optional token to observe for cancellation requests.

Returns

A collection of DocNode representing the harvested documentation.

Enum

DocHarvestHealthStatus

Source

Describes the overall health of the latest RazorDocs harvest snapshot.

Remarks

Numeric values are a stable public compatibility contract for persisted and serialized representations. Do not remove, reorder, or renumber existing members.

Enum

DocHarvesterHealthStatus

Source

Describes one configured harvester's contribution to a RazorDocs harvest snapshot.

Remarks

Numeric values are a stable public compatibility contract for persisted and serialized representations. Do not remove, reorder, or renumber existing members.

Enum

DocHarvestDiagnosticSeverity

Source

Describes the severity of a structured RazorDocs harvest diagnostic.

Remarks

Numeric values are a stable public compatibility contract for persisted and serialized representations. Do not remove, reorder, or renumber existing members.

Enum

DocPublicSection

Source

Enumerates the built-in public documentation sections used by RazorDocs.

Remarks

Numeric values are a stable public compatibility contract for persisted and serialized representations. Do not remove, reorder, or renumber existing members. Presentation order is defined by DocPublicSectionCatalog.OrderedSections, so renderers should not infer UI ordering from enum ordinals.

Type

RazorDocsHarvestFailedException

Source

Exception thrown by strict RazorDocs startup preflight when every configured harvester fails.

Remarks

The exception message and Summary intentionally contain only redacted harvest-health fields. Repository roots, raw exception messages, stack traces, and diagnostic cause text stay in host logs and are not copied into this public failure contract.

Property

Summary

DocHarvestFailureSummary Summary { get; } Source

Gets the redacted strict-harvest failure summary.

Type

DocHarvestFailureSummary

Source

Redacted strict-harvest failure summary safe for public exception messages and export output.

Parameters

  • StatusThe aggregate harvest-health status that triggered strict failure.
  • GeneratedUtcThe timestamp for the cached harvest snapshot generation.
  • TotalHarvestersNumber of configured harvesters in the failed snapshot.
  • SuccessfulHarvestersNumber of harvesters that completed with docs or an intentional empty result.
  • FailedHarvestersNumber of harvesters that failed, timed out, or canceled.
  • TotalDocsNumber of final docs in the failed snapshot.
  • DiagnosticsRedacted diagnostic entries copied from the failed snapshot.
Method

FromSnapshot

DocHarvestFailureSummary FromSnapshot(DocHarvestHealthSnapshot health) Source

Creates a redacted strict-harvest failure summary from a harvest-health snapshot.

Parameters

  • healthThe harvest-health snapshot to summarize.

Returns

A redacted summary that omits repository roots, raw exception details, and diagnostic cause text.

Type

DocHarvestFailureDiagnostic

Source

Redacted strict-harvest diagnostic safe for public exception messages and export output.

Parameters

  • CodeStable diagnostic code for machine-readable branching and tests.
  • SeverityDiagnostic severity copied from the source diagnostic.
  • HarvesterTypeConcrete harvester type when the diagnostic belongs to one harvester.
  • ProblemOperator-facing problem statement.
  • FixSuggested recovery action.
Method

FromDiagnostic

DocHarvestFailureDiagnostic FromDiagnostic(DocHarvestDiagnostic diagnostic) Source

Creates a redacted strict-harvest diagnostic from a harvest-health diagnostic.

Parameters

  • diagnosticThe source diagnostic to redact.

Returns

A diagnostic that omits cause text and raw exception details.

Type

RazorDocsVersionArchiveViewModel

Source

View model for the public RazorDocs version archive and degraded entry surface.

Remarks

The same model drives both the dedicated archive page and the degraded route-root recovery surface when no healthy recommended release can be mounted at the stable entry alias. PreviewHref always points at the current source-backed preview surface, while VersionsHref stays on the stable archive URL. Versions preserves the authored catalog order and should be treated as a read-only projection of the resolved catalog state.

Property

Heading

string Heading { get; init; } Source

Gets the page heading.

Property

Description

string Description { get; init; } Source

Gets the orientation copy shown above the archive list.

Property

AvailabilityMessage

string? AvailabilityMessage { get; init; } Source

Gets optional explanatory copy shown when the stable route-root alias cannot mount a recommended released tree.

Remarks

This is typically null on the dedicated archive page and populated only for the degraded route-root recovery experience.

Property

PreviewHref

string PreviewHref { get; init; } Source

Gets the live preview docs URL.

Remarks

This points at the configured source-backed preview surface, such as /docs/next for the default route family or /foo/bar/next for a custom one.

Property

VersionsHref

string VersionsHref { get; init; } Source

Gets the stable archive URL.

Property

Versions

IReadOnlyList<RazorDocsVersionArchiveEntryViewModel> Versions { get; init; } Source

Gets the available published versions shown in the archive.

Type

RazorDocsVersionArchiveEntryViewModel

Source

Represents one release entry in the public RazorDocs version archive.

Remarks

Entries may describe either a healthy exact-version tree with an Href target or an unavailable release that should remain visible in the archive with an explanatory availability message. IsRecommended identifies the exact release currently mirrored at the stable route-root alias, while IsAvailable controls whether the entry can link directly to that exact version. Advisory and support labels are independent: an unavailable or deprecated release may still surface an advisory, and a recommended release may still carry a warning label when the catalog says readers should see one.

Property

Version

string Version { get; init; } Source

Gets the exact published version identifier.

Property

Label

string Label { get; init; } Source

Gets the reader-facing label.

Property

Summary

string? Summary { get; init; } Source

Gets optional summary copy for the release.

Property

Href

string? Href { get; init; } Source

Gets the exact-version URL when the release is available.

Remarks

This is null when IsAvailable is false and the archive should render the release as informational-only.

Property

IsRecommended

bool IsRecommended { get; init; } Source

Gets a value indicating whether this version is the recommended stable alias target.

Property

IsAvailable

bool IsAvailable { get; init; } Source

Gets a value indicating whether the exact-version tree is currently available.

Property

SupportStateLabel

string SupportStateLabel { get; init; } Source

Gets the human-readable support-state label.

Property

AdvisoryLabel

string? AdvisoryLabel { get; init; } Source

Gets the human-readable advisory label when a release warning should be surfaced.

Remarks

This is null when no release-level warning badge should be rendered.

Property

AvailabilityMessage

string? AvailabilityMessage { get; init; } Source

Gets the availability explanation when the release tree is unavailable.

Remarks

This is usually populated only when IsAvailable is false and explains why the exact-version tree could not be mounted or linked.

Type

SearchPageViewModel

Source

Describes the server-rendered shell for the dedicated docs search workspace.

Parameters

  • TitleThe primary page heading shown above the workspace controls.
  • OrientationA short orientation sentence that explains what users can discover from the workspace.
  • StarterHintHelper copy shown in the starter state before a query or filter is applied.
  • SearchPlaceholderPlaceholder text for the advanced search input.
  • SuggestedQueriesStarter-state suggestions rendered as clickable chips. Empty lists are allowed, but the shell is designed around a curated set of useful first queries.
  • FailureFallbackLinksOrdered recovery links shown when the search runtime or index cannot be loaded. Include at least one non-search path that still helps users continue through the docs set.

Remarks

This model is rendered before the client-side search index is available so the page can show stable loading, starter, and failure states even when the search payload is slow or unavailable. All members are required and should be supplied as non-null values. The list properties render in the order provided. Use SearchPageViewModel for the server-rendered shell contract and recovery guidance, not for live search results or client-side facet state. Callers should prefer empty lists over null for SuggestedQueries and FailureFallbackLinks. Suggested queries and fallback links are displayed in the supplied order, so place the highest-signal actions first. Avoid relying on client-side mutation of this model after render, and avoid using external absolute URLs in SearchPageFallbackLink.Href because the shell assumes app-relative navigation semantics.

Type

RazorDocsHarvestHealthResponse

Source

Redacted operator-facing RazorDocs harvest health response shared by the HTML and JSON health surfaces.

Remarks

This contract intentionally omits repository roots, diagnostic cause text, raw exception messages, stack traces, and other host-local details. Use DocAggregator.GetHarvestHealthAsync(System.Threading.CancellationToken) for server-side inspection when trusted code needs the full snapshot.

Method

FromSnapshot

RazorDocsHarvestHealthResponse FromSnapshot(DocHarvestHealthSnapshot health) Source

Creates a redacted response from the full server-side harvest health snapshot.

Parameters

  • healthThe server-side harvest health snapshot.

Returns

A response that is safe to serialize to clients.

Property

Status

string Status { get; init; } Source

Gets the aggregate harvest status name.

Property

GeneratedUtc

DateTimeOffset GeneratedUtc { get; init; } Source

Gets the UTC timestamp when the cached harvest snapshot was generated.

Property

Verification

RazorDocsHarvestHealthVerification Verification { get; init; } Source

Gets the machine-checkable verification rollup for the response.

Property

TotalHarvesters

int TotalHarvesters { get; init; } Source

Gets the number of configured harvesters in the snapshot.

Property

SuccessfulHarvesters

int SuccessfulHarvesters { get; init; } Source

Gets the number of harvesters that completed with docs or a valid empty result.

Property

FailedHarvesters

int FailedHarvesters { get; init; } Source

Gets the number of harvesters that failed, timed out, or canceled.

Property

TotalDocs

int TotalDocs { get; init; } Source

Gets the number of documentation nodes published by the final cached docs snapshot.

Property

Harvesters

IReadOnlyList<RazorDocsHarvesterHealthResponse> Harvesters { get; init; } Source

Gets the per-harvester redacted health entries.

Property

Diagnostics

IReadOnlyList<RazorDocsHarvestDiagnosticResponse> Diagnostics { get; init; } Source

Gets redacted diagnostic entries for failed, degraded, or noteworthy states.

Type

RazorDocsHarvestHealthVerification

Source

Machine-checkable verification rollup for a RazorDocs harvest health response.

Property

Ok

bool Ok { get; init; } Source

Gets a value indicating whether the harvest state should pass local or CI verification.

Property

HttpStatusCode

int HttpStatusCode { get; init; } Source

Gets the HTTP status code RazorDocs uses for this response.

Type

RazorDocsHarvesterHealthResponse

Source

Redacted per-harvester health entry in the operator-facing harvest health response.

Property

HarvesterType

string HarvesterType { get; init; } Source

Gets the concrete harvester type name.

Property

Status

string Status { get; init; } Source

Gets the harvester status name.

Property

DocCount

int DocCount { get; init; } Source

Gets the number of documentation nodes returned by the harvester before RazorDocs post-processing.

Property

Diagnostic

RazorDocsHarvestDiagnosticResponse? Diagnostic { get; init; } Source

Gets the redacted diagnostic explaining a failed, timed-out, or canceled harvester.

Type

RazorDocsHarvestDiagnosticResponse

Source

Redacted diagnostic entry in the operator-facing harvest health response.

Property

Code

string Code { get; init; } Source

Gets the stable diagnostic code.

Property

Severity

string Severity { get; init; } Source

Gets the diagnostic severity name.

Property

HarvesterType

string? HarvesterType { get; init; } Source

Gets the concrete harvester type when the diagnostic belongs to one harvester.

Property

Problem

string Problem { get; init; } Source

Gets the operator-facing problem statement.

Property

Fix

string Fix { get; init; } Source

Gets the suggested operator or docs-author recovery action.

Type

DocPublicSectionCatalog

Source

Defines the canonical public-section labels, slugs, purpose copy, and alias lookup rules used by RazorDocs.

Method

GetLabel

string GetLabel(DocPublicSection section) Source

Gets the canonical display label for the specified public section.

Parameters

  • sectionThe section whose label should be returned.

Returns

The reader-facing label, such as Start Here or API Reference.

Method

GetSlug

string GetSlug(DocPublicSection section) Source

Gets the canonical stable route slug for the specified public section.

Parameters

  • sectionThe section whose slug should be returned.

Returns

A lower-case hyphenated slug suitable for {DocsRootPath}/sections/{slug} routes.

Method

GetPurpose

string GetPurpose(DocPublicSection section) Source

Gets the short purpose statement used to explain why a public section exists.

Parameters

  • sectionThe section whose purpose copy should be returned.

Returns

The summary text shown in section-first navigation surfaces.

Method

GetHref

2 overloads
string GetHref(DocPublicSection section) Source

Gets the default stable public route for the specified section.

Parameters

  • sectionThe section whose href should be returned.

Returns

The default /docs/sections/{slug} route for the section.

Remarks

This overload always roots the returned href at the default /docs surface. Callers that are rendering links on the current live surface should prefer GetHref(DocPublicSection, string) so custom route roots and preview roots are honored. The route slug is always produced by GetSlug(DocPublicSection).

string GetHref(DocPublicSection section, string docsRootPath) Source

Gets the canonical public-section route rooted at the caller's current docs surface.

Parameters

  • sectionThe section whose href should be returned.
  • docsRootPathThe pre-normalized, app-relative docs root path to anchor the section route under. Callers are expected to pass the validated live docs root from RazorDocsRoutingOptions.DocsRootPath or Services.DocsUrlBuilder.CurrentDocsRootPath, not an arbitrary or unvalidated value.

Returns

The canonical {docsRootPath}/sections/{slug} route for the section, or /sections/{slug} when docsRootPath is exactly /.

Remarks

This overload exists for mounted live docs surfaces such as /docs/next or root-mounted docs at /. It special-cases / so root-mounted hosts emit /sections/{slug} instead of //sections/{slug}. The slug portion is always derived from GetSlug(DocPublicSection). Passing a non-normalized value such as /docs/ can produce incorrect hard-coded links, so callers should normalize and validate docsRootPath before invoking this overload.

Method

TryResolve

bool TryResolve(string? value, out DocPublicSection section) Source

Resolves an authored section value using canonical labels, canonical slugs, or known aliases.

Parameters

  • valueThe authored value to resolve.
  • sectionWhen this method returns true, contains the resolved public section.

Returns

true when value matches a known label, slug, or alias after normalization; otherwise, false.

Remarks

Resolution is case-insensitive and ignores surrounding whitespace plus non-alphanumeric separators so values such as Start Here, start-here, and start_here all resolve to the same section.

Method

TryResolveSlug

bool TryResolveSlug(string? slug, out DocPublicSection section) Source

Resolves only canonical section-route slugs for /docs/sections/{slug} URLs.

Parameters

  • slugThe incoming route slug to resolve.
  • sectionWhen this method returns true, contains the resolved public section.

Returns

true when slug matches one canonical section slug after trimming and case-normalization; otherwise, false.

Remarks

Unlike TryResolve, this method does not accept labels or aliases. Callers that want to support legacy or user-friendly alias inputs should resolve them separately and redirect to GetHref(DocPublicSection).

Method

BuildLookup

IReadOnlyDictionary<string, DocPublicSection> BuildLookup() Source

Builds the lookup table used for authored metadata values that may use labels, slugs, or aliases.

Returns

A normalized dictionary that maps authored section identifiers to their canonical section enum.

Method

BuildSlugLookup

IReadOnlyDictionary<string, DocPublicSection> BuildSlugLookup() Source

Builds the lookup table used for canonical section-route slugs.

Returns

A normalized dictionary that accepts only canonical slugs for section-route resolution.

Method

NormalizeKey

string NormalizeKey(string? value) Source

Normalizes authored section metadata so labels, slugs, and aliases can share one lookup table.

Parameters

  • valueThe authored value to normalize.

Returns

A lowercase alphanumeric key, or an empty string when value is blank.

Method

NormalizeSlug

string NormalizeSlug(string? value) Source

Normalizes an incoming section-route slug while preserving the canonical hyphenated slug contract.

Parameters

  • valueThe incoming route slug.

Returns

The trimmed lowercase slug, or an empty string when value is blank.

Property

OrderedSections

IReadOnlyList<DocPublicSection> OrderedSections { get; } Source

Gets the public sections in their intended presentation order for docs home and sidebar surfaces.

Type

Definition

Source

Describes one built-in public section, including its canonical display label, stable route slug, and accepted aliases.