ContentClient
Properties
Section titled “Properties”delivery
Section titled “delivery”
readonlydelivery:DeliveryClient
The low-level client this one is built on — nothing is hidden.
strategy
Section titled “strategy”
readonlystrategy:ResolveStrategy
The strategy in force for this client.
Methods
Section titled “Methods”getNavigation()
Section titled “getNavigation()”getNavigation(
anchor?,options?):Promise<NavigationTree>
The published Experience tree, for navigation — site and locale come from this client, so a consumer names only the anchor and what it wants relative to it. Cached, deduped, and persisted like every other resolve.
anchor is a node Guid or a published path; omitted, the site root. Each named use case is one
call: ['ancestors', 'self'] a breadcrumb, ['children'] a nav menu, ['siblings'] a pager.
Parameters
Section titled “Parameters”anchor?
Section titled “anchor?”string
options?
Section titled “options?”Returns
Section titled “Returns”Promise<NavigationTree>
getTree()
Section titled “getTree()”getTree(
options?):Promise<NavigationTree>
The whole site tree in one call — every navigation question then answered locally.
Parameters
Section titled “Parameters”options?
Section titled “options?”Omit<NavigationOptions, "include">
Returns
Section titled “Returns”Promise<NavigationTree>
invalidate()
Section titled “invalidate()”invalidate():
void
Drops every cached result and the memoized site/locale, including anything persisted.
Returns
Section titled “Returns”void
peekLocation()
Section titled “peekLocation()”peekLocation(
location):PersistedExperience|undefined
The persisted result of the last successful resolveLocation for this location, if any —
synchronous, no request. undefined when persistence is off, storage is unavailable, there is
no entry, it has expired, or preview is activated.
Parameters
Section titled “Parameters”location
Section titled “location”Returns
Section titled “Returns”PersistedExperience | undefined
peekReference()
Section titled “peekReference()”peekReference<
TContent>(descriptor):PersistedReference<TContent> |undefined
The persisted result of the last successful resolveReference for this descriptor, if any — synchronous, no request. Same absence rules as peekLocation. TContent asserts, exactly as it does on resolveReference.
Type Parameters
Section titled “Type Parameters”TContent
Section titled “TContent”TContent = ContentDocument
Parameters
Section titled “Parameters”descriptor
Section titled “descriptor”Returns
Section titled “Returns”PersistedReference<TContent> | undefined
peekTree()
Section titled “peekTree()”peekTree(
anchor?,options?):NavigationTree|undefined
The persisted result of the last successful matching getNavigation/getTree, if any — synchronous, no request. Same absence rules as peekLocation.
Parameters
Section titled “Parameters”anchor?
Section titled “anchor?”string
options?
Section titled “options?”Returns
Section titled “Returns”NavigationTree | undefined
resolveLocale()
Section titled “resolveLocale()”resolveLocale():
Promise<string|undefined>
Returns
Section titled “Returns”Promise<string | undefined>
resolveLocation()
Section titled “resolveLocation()”resolveLocation(
location,overrides?):Promise<ExperienceResult>
Resolves whatever lives at a location — invoke it on every router change.
Parameters
Section titled “Parameters”location
Section titled “location”overrides?
Section titled “overrides?”Returns
Section titled “Returns”Promise<ExperienceResult>
resolveReference()
Section titled “resolveReference()”resolveReference<
TContent>(descriptor,overrides?,owner?):Promise<ExpandedReference<TContent>>
Resolves one unexpanded reference (the normalized strategy), applying the descriptor’s own
contextual overlay. An already-resolved value is returned as-is. owner identifies the fetch
that produced this descriptor — required to resolve an Adapter-bearing descriptor, since only a
resolve of the owning document can apply the edge’s Adapter; omitted, an adapted descriptor
throws adapter_requires_server_resolve (the low-level, owner-less contract). With an owner, the
SDK resolves it at depth 1 first, escalating to full once (bounded, cached) if the edge is still
unreached there — the case of a relayed Presentation nested one hop deeper.
Type Parameters
Section titled “Type Parameters”TContent
Section titled “TContent”TContent = ContentDocument
Parameters
Section titled “Parameters”descriptor
Section titled “descriptor”overrides?
Section titled “overrides?”owner?
Section titled “owner?”Returns
Section titled “Returns”Promise<ExpandedReference<TContent>>
resolveSite()
Section titled “resolveSite()”resolveSite():
Promise<ResolvedSite>
Returns
Section titled “Returns”Promise<ResolvedSite>