@voltro/cms 0.86.0 → 0.88.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5484 -0
- package/README.md +138 -0
- package/THIRD-PARTY-NOTICES.md +1511 -276
- package/dist/ContentForm.js +1 -2
- package/dist/RichDocumentEditor.js +1 -2
- package/dist/RichDocumentView.js +82 -38
- package/dist/RichTextSurface.js +1 -2
- package/dist/aiCandidates.js +4 -5
- package/dist/aiOperations.js +1 -2
- package/dist/applicationBuildSnapshotService.js +100 -0
- package/dist/assetRenditions.js +101 -0
- package/dist/assetRevision.js +45 -0
- package/dist/assetUseRights.js +71 -0
- package/dist/audiences.js +1 -2
- package/dist/availability.js +20 -18
- package/dist/blueprint.js +76 -77
- package/dist/build.d.ts +3063 -0
- package/dist/build.js +37 -0
- package/dist/buildApplicationAdmission.js +15 -0
- package/dist/buildApplicationCatalog.js +135 -0
- package/dist/buildApplicationCatalogTable.js +23 -0
- package/dist/buildApplicationRest.js +98 -0
- package/dist/buildApplicationUpload.js +110 -0
- package/dist/buildSnapshot.js +400 -0
- package/dist/buildSnapshotApplicationPin.js +31 -0
- package/dist/buildSnapshotRest.js +209 -0
- package/dist/buildSnapshotService.js +264 -0
- package/dist/buildSnapshotTables.js +24 -0
- package/dist/bulk.js +72 -72
- package/dist/cacheIdentity.js +1 -2
- package/dist/changes.js +280 -64
- package/dist/cmsContext.js +1 -2
- package/dist/collections.js +1 -2
- package/dist/consent.js +6 -7
- package/dist/contentLocations.js +52 -0
- package/dist/contentProjection.js +82 -0
- package/dist/contentRouteIdentity.js +12 -0
- package/dist/contentRouteMaterializer.js +96 -0
- package/dist/contentRouteTypes.js +38 -0
- package/dist/contentSeo.js +188 -0
- package/dist/contentTreePath.js +59 -0
- package/dist/contentType.js +121 -105
- package/dist/contentValues.js +17 -0
- package/dist/contentfulImport.js +1 -2
- package/dist/copies.js +4 -5
- package/dist/cutover.js +1 -2
- package/dist/deliveryChecks.js +1 -2
- package/dist/domainHost.js +6 -0
- package/dist/domains.js +82 -89
- package/dist/draftTexts.js +38 -39
- package/dist/duplicates.js +24 -25
- package/dist/edgePurge.js +1 -2
- package/dist/editHistory.js +1 -2
- package/dist/effectForm.js +1 -2
- package/dist/environmentAliases.js +137 -0
- package/dist/environments.js +108 -71
- package/dist/errors.js +55 -16
- package/dist/experiments.js +8 -9
- package/dist/exposure.js +1 -2
- package/dist/extensionManifest.js +2 -3
- package/dist/extensions.js +1 -2
- package/dist/fieldSchema.js +1 -2
- package/dist/formStrings.js +1 -2
- package/dist/frontendBindings.js +98 -0
- package/dist/frontendMedia.js +17 -0
- package/dist/glossary.js +1 -2
- package/dist/history.js +1 -2
- package/dist/htmlImport.js +1 -2
- package/dist/index.d.ts +760 -47
- package/dist/index.js +89 -73
- package/dist/initializePublicRoutes.js +27 -0
- package/dist/liveContentRouteView.js +75 -0
- package/dist/media.js +1 -2
- package/dist/metrics.js +1 -2
- package/dist/migration.js +1 -2
- package/dist/migrationStages.js +1 -2
- package/dist/nativeOutputDeploymentService.js +204 -0
- package/dist/outputActivation.js +233 -0
- package/dist/outputActivationOrigin.js +50 -0
- package/dist/outputActivationStore.js +410 -0
- package/dist/outputActivationTables.js +10 -0
- package/dist/outputActivationTarget.js +80 -0
- package/dist/outputActivationTargetTable.js +24 -0
- package/dist/outputDeployment.js +173 -0
- package/dist/outputDeploymentRest.js +167 -0
- package/dist/outputDeploymentService.js +240 -0
- package/dist/outputRouteGraph.js +176 -0
- package/dist/outputSafetyArtifact.js +146 -0
- package/dist/outputTargetRest.js +61 -0
- package/dist/pathSegmentEncoding.js +3 -0
- package/dist/presenceAnchors.js +1 -2
- package/dist/preview.js +1 -2
- package/dist/privateCmsTransport.js +75 -0
- package/dist/privateNativeRouteReservation.js +9 -0
- package/dist/promotion.js +69 -61
- package/dist/publicBuild.js +89 -0
- package/dist/publicBuildRest.js +97 -0
- package/dist/publicBuildService.js +62 -0
- package/dist/publicOutputHttp.js +128 -0
- package/dist/publicOutputService.js +286 -0
- package/dist/publicPresentation.js +16 -0
- package/dist/publicRouteDispositionAdmission.js +37 -0
- package/dist/publicRouteHistoryStore.js +11 -0
- package/dist/publicRouteHistoryView.js +33 -0
- package/dist/publicRouteIntegrity.js +4 -0
- package/dist/publicRouteMutation.js +5 -0
- package/dist/publicRouteNamespace.js +133 -0
- package/dist/publicRoutePublication.js +35 -0
- package/dist/publicRouteRegistry.js +16 -0
- package/dist/publicRouteRegistryBinding.js +193 -0
- package/dist/publicRouteRegistryDefinition.js +75 -0
- package/dist/publicRouteSitePublication.js +39 -0
- package/dist/publicRouteTables.js +12 -0
- package/dist/publicRouteUrl.js +17 -0
- package/dist/publicationSeo.js +51 -0
- package/dist/publicationState.js +295 -0
- package/dist/quality.js +9 -10
- package/dist/reconfigurePublicRoutes.js +40 -0
- package/dist/recurrence.js +1 -2
- package/dist/redirects.js +105 -75
- package/dist/referenceGraph.js +16 -16
- package/dist/references.js +3 -4
- package/dist/release.js +178 -143
- package/dist/renderReadAuthority.js +42 -0
- package/dist/renderReadGrant.js +136 -0
- package/dist/rest.js +1 -2
- package/dist/review.js +29 -30
- package/dist/richDocument.js +56 -27
- package/dist/richInline.js +1 -2
- package/dist/routeDispositionGraph.js +43 -0
- package/dist/routeDispositionRest.js +50 -0
- package/dist/routeDispositionService.js +72 -0
- package/dist/routeDispositionStore.js +288 -0
- package/dist/routeDispositionTables.js +4 -0
- package/dist/routeDispositions.js +90 -0
- package/dist/routeHistoryStorage.js +319 -0
- package/dist/routeHistoryStore.js +11 -0
- package/dist/schedule.js +37 -38
- package/dist/search.js +1 -2
- package/dist/selectionIntent.js +1 -2
- package/dist/seo.js +2 -3
- package/dist/series.js +12 -13
- package/dist/share.js +14 -15
- package/dist/siteBindings.js +158 -0
- package/dist/siteBuildCandidate.js +103 -0
- package/dist/siteDelivery.js +114 -0
- package/dist/siteState.js +46 -0
- package/dist/snapshotAddressGraph.js +54 -0
- package/dist/snapshotAddressRead.js +72 -0
- package/dist/snapshotAppConsumer.js +70 -0
- package/dist/snapshotAppExecution.js +101 -0
- package/dist/snapshotApplication.js +74 -0
- package/dist/snapshotApprovedRouteDispositions.js +43 -0
- package/dist/snapshotAssetAssembly.js +69 -0
- package/dist/snapshotAssetAssemblyRest.js +49 -0
- package/dist/snapshotBindingRead.js +60 -0
- package/dist/snapshotCodeSeo.js +28 -0
- package/dist/snapshotComponent.js +33 -0
- package/dist/snapshotComponentSource.js +23 -0
- package/dist/snapshotConsumer.js +86 -0
- package/dist/snapshotContentIdentity.js +9 -0
- package/dist/snapshotDefinitions.js +263 -0
- package/dist/snapshotDocumentAssembly.js +192 -0
- package/dist/snapshotDocumentAssemblyRest.js +83 -0
- package/dist/snapshotDocumentProjection.js +201 -0
- package/dist/snapshotDocumentTransfer.js +34 -0
- package/dist/snapshotDocumentTransferRest.js +79 -0
- package/dist/snapshotDomains.js +55 -0
- package/dist/snapshotEnvironment.js +30 -0
- package/dist/snapshotFieldPlan.js +84 -0
- package/dist/snapshotFrontend.js +102 -0
- package/dist/snapshotLink.js +7 -0
- package/dist/snapshotMedia.js +110 -0
- package/dist/snapshotMediaCapture.js +245 -0
- package/dist/snapshotMediaFields.js +224 -0
- package/dist/snapshotMediaRead.js +184 -0
- package/dist/snapshotMediaReader.js +12 -0
- package/dist/snapshotObservation.js +15 -0
- package/dist/snapshotObservedRouteHistory.js +33 -0
- package/dist/snapshotOutputTransfer.js +77 -0
- package/dist/snapshotPageLoader.js +6 -0
- package/dist/snapshotPageSeo.js +58 -0
- package/dist/snapshotPathLocale.js +14 -0
- package/dist/snapshotPresentation.js +85 -0
- package/dist/snapshotPresentationPolicy.js +11 -0
- package/dist/snapshotProjection.js +118 -0
- package/dist/snapshotPublicAccess.js +160 -0
- package/dist/snapshotPublicRouteHistory.js +39 -0
- package/dist/snapshotReadAdmission.js +37 -0
- package/dist/snapshotRedirectOutput.js +150 -0
- package/dist/snapshotRedirectTargets.js +23 -0
- package/dist/snapshotRedirects.js +131 -0
- package/dist/snapshotReference.js +7 -0
- package/dist/snapshotReferenceAddress.js +9 -0
- package/dist/snapshotReferenceGraph.js +78 -0
- package/dist/snapshotReferenceRead.js +64 -0
- package/dist/snapshotRelease.js +98 -0
- package/dist/snapshotRender.js +360 -0
- package/dist/snapshotRenderDependencies.js +177 -0
- package/dist/snapshotRenditions.js +87 -0
- package/dist/snapshotRichDocument.js +61 -0
- package/dist/snapshotRoleTransfer.js +105 -0
- package/dist/snapshotRoleTransferRest.js +98 -0
- package/dist/snapshotRouteAdmission.js +70 -0
- package/dist/snapshotRouteDispatch.js +110 -0
- package/dist/snapshotRouteDispositionPlan.js +72 -0
- package/dist/snapshotRouteRead.js +42 -0
- package/dist/snapshotRoutes.js +78 -0
- package/dist/snapshotRouting.js +112 -0
- package/dist/snapshotSeo.js +178 -0
- package/dist/snapshotSeoControls.js +100 -0
- package/dist/snapshotSeoDocumentInventory.js +114 -0
- package/dist/snapshotSeoDocuments.js +128 -0
- package/dist/snapshotSeoMerge.js +84 -0
- package/dist/snapshotSeoMetadata.js +136 -0
- package/dist/snapshotSeoOutput.js +172 -0
- package/dist/snapshotSeoPathSets.js +104 -0
- package/dist/snapshotSeoRead.js +87 -0
- package/dist/snapshotSite.js +127 -0
- package/dist/snapshotSitemapFiles.js +35 -0
- package/dist/snapshotTreeDependencies.js +57 -0
- package/dist/snapshotTreeLoader.js +9 -0
- package/dist/snapshotTreeRead.js +157 -0
- package/dist/staticPathSet.js +176 -0
- package/dist/staticPathSetRest.js +128 -0
- package/dist/staticPathSetService.js +248 -0
- package/dist/staticPathSetStore.js +337 -0
- package/dist/stewardship.js +2 -3
- package/dist/taxonomy.js +1 -2
- package/dist/team.js +1 -2
- package/dist/templates.js +2 -3
- package/dist/trackChanges.js +1 -2
- package/dist/translation.js +1 -2
- package/dist/tree.js +10 -11
- package/dist/usage.js +1 -2
- package/dist/validation.js +54 -55
- package/dist/visualEditing.js +1 -2
- package/dist/web.d.ts +709 -7
- package/dist/web.js +50 -33
- package/dist/workflow.js +9 -10
- package/dist/write.js +251 -227
- package/dist/xliff.js +1 -2
- package/package.json +21 -7
package/dist/build.d.ts
ADDED
|
@@ -0,0 +1,3063 @@
|
|
|
1
|
+
import { ApiWorkload } from '@voltro/protocol';
|
|
2
|
+
import { DataStore } from '@voltro/database';
|
|
3
|
+
import { Effect } from 'effect';
|
|
4
|
+
import { PluginHttpRoute } from '@voltro/protocol';
|
|
5
|
+
import { PluginHttpRouteByteStream } from '@voltro/protocol';
|
|
6
|
+
import { PluginHttpRouteRequest } from '@voltro/protocol';
|
|
7
|
+
import { PluginHttpRouteResult } from '@voltro/protocol';
|
|
8
|
+
import { PluginHttpRouteStream } from '@voltro/protocol';
|
|
9
|
+
import { PluginHttpRouteStreamRequest } from '@voltro/protocol';
|
|
10
|
+
import { PublicApiDescriptor } from '@voltro/protocol/rest';
|
|
11
|
+
import { RenditionDerivation } from '@voltro/plugin-storage';
|
|
12
|
+
import { RestCache } from '@voltro/protocol/rest';
|
|
13
|
+
import { RestCors } from '@voltro/protocol/rest';
|
|
14
|
+
import { RestGuard } from '@voltro/protocol/rest';
|
|
15
|
+
import { RestMethod } from '@voltro/protocol/rest';
|
|
16
|
+
import { RestRateLimit } from '@voltro/protocol/rest';
|
|
17
|
+
import { RestRouteContext } from '@voltro/protocol/rest';
|
|
18
|
+
import { RestRouteDescriptor } from '@voltro/protocol/rest';
|
|
19
|
+
import { RestRouteExample } from '@voltro/protocol/rest';
|
|
20
|
+
import { RestRouteProjection } from '@voltro/protocol/rest';
|
|
21
|
+
import { Schema } from 'effect';
|
|
22
|
+
import { StorageCustodyShape } from '@voltro/plugin-storage';
|
|
23
|
+
import { TableLike } from '@voltro/database';
|
|
24
|
+
import { YieldableError } from 'effect/Cause';
|
|
25
|
+
|
|
26
|
+
/** Region receipts must have been produced by real region staging adapters.
|
|
27
|
+
* This atomically changes the logical head only; no CMS publication/audit row
|
|
28
|
+
* is modified and no old set or monotone safety row is removed. */
|
|
29
|
+
export declare const activateOutputSet: (tx: DataStore, supplied: OutputActivationSet, options: {
|
|
30
|
+
readonly probe: OutputActivationProbe;
|
|
31
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
32
|
+
readonly now: number;
|
|
33
|
+
readonly receipts: ReadonlyArray<OutputRegionReceipt>;
|
|
34
|
+
readonly regionKeys: Readonly<Record<string, ReadonlyArray<RenderReadKey>>>;
|
|
35
|
+
readonly admit: OutputActivationAdmission;
|
|
36
|
+
readonly readRoutes: OutputActivationRouteInventory;
|
|
37
|
+
}) => Promise<OutputActivationMarker>;
|
|
38
|
+
|
|
39
|
+
/** Validate against the captured policy, not a live purpose or a cookie version. */
|
|
40
|
+
export declare const admitSnapshotPresentation: (purposes: ReadonlyArray<SnapshotConsentPurpose>, supplied: unknown) => SnapshotPresentation;
|
|
41
|
+
|
|
42
|
+
/** Declares the original-file field of a versioned asset document. It does
|
|
43
|
+
* not imply ingestion, creative approval, rights or public delivery fitness. */
|
|
44
|
+
declare interface AssetConfig {
|
|
45
|
+
readonly file: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/** Which fields carry a type's availability. Validated by `defineContentType`. */
|
|
49
|
+
declare interface AvailabilityConfig {
|
|
50
|
+
/** A date or datetime field: usable up to (excluding) this moment. */
|
|
51
|
+
readonly until?: string;
|
|
52
|
+
/** A boolean field: `true` withdraws the document at once. */
|
|
53
|
+
readonly blocked?: string;
|
|
54
|
+
/** A date or datetime field: usable from this moment on. */
|
|
55
|
+
readonly from?: string;
|
|
56
|
+
/** A list-of-text field of territory codes (ISO 3166-1 alpha-2): usable only there. Empty: everywhere. */
|
|
57
|
+
readonly territories?: string;
|
|
58
|
+
/** A list-of-text field of channels (`web`, `app`, `print`, …): usable only on these. Empty: on every channel. */
|
|
59
|
+
readonly channels?: string;
|
|
60
|
+
/** A list-of-text field of purposes (`editorial`, `advertising`, …): usable only for these. Empty: for every purpose. */
|
|
61
|
+
readonly purposes?: string;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/** Persist the actual admitted deploy after its artifact/contract check. A
|
|
65
|
+
* policy change uses the same CAS and lock as deployment, even for same app. */
|
|
66
|
+
export declare const bindOutputDeployment: (tx: DataStore, suppliedScope: OutputActivationScope, input: {
|
|
67
|
+
readonly expectedRevision: number;
|
|
68
|
+
readonly app: OutputActivationManifest["app"];
|
|
69
|
+
readonly renderPolicyDigest: string;
|
|
70
|
+
}) => Promise<OutputDeployment>;
|
|
71
|
+
|
|
72
|
+
/** One independently resumable publication stream. Tenant must be explicit. */
|
|
73
|
+
declare interface ChangeFeedScope {
|
|
74
|
+
readonly tenantId: string;
|
|
75
|
+
readonly site: string;
|
|
76
|
+
readonly environment: string;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export declare const CMS_OUTPUT_DEPLOY_SCOPE = "cms:deploy";
|
|
80
|
+
|
|
81
|
+
export declare interface CmsAdmittedPublicDocument extends CmsPublicOutputFile {
|
|
82
|
+
readonly admission: CmsPublicDocumentAdmission;
|
|
83
|
+
readonly source?: unknown;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export declare interface CmsApplicationBuildSnapshotsOptions extends Omit<CmsBuildSnapshotsOptions, 'code' | 'app' | 'execution' | 'routeDiscovery'> {
|
|
87
|
+
/** Trusted server catalog of independently admitted retained applications.
|
|
88
|
+
* Unknown pins must refuse. Never derive a filesystem root, compiler or
|
|
89
|
+
* import permission directly from this comparison supplied by a request. */
|
|
90
|
+
readonly resolveApplication: (pin: CmsBuildSnapshotApplicationPin) => Promise<CmsBuildSnapshotPreparedApplication>;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
export declare interface CmsBuildApplicationAdmission {
|
|
94
|
+
readonly deploymentId: string;
|
|
95
|
+
readonly archiveId: string;
|
|
96
|
+
readonly application: CmsBuildSnapshotApplicationPin;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export declare interface CmsBuildApplicationCatalog {
|
|
100
|
+
readonly admit: (input: CmsBuildApplicationAdmission & {
|
|
101
|
+
readonly credential: string;
|
|
102
|
+
}, bytes: AsyncIterable<Uint8Array>) => Effect.Effect<CmsBuildApplicationAdmission, CmsOutputDeploymentUnavailable>;
|
|
103
|
+
/** Recover the original admission after a lost acknowledgement. This checks
|
|
104
|
+
* current deployment authority and native custody, without renewing it. */
|
|
105
|
+
readonly inspect: (input: {
|
|
106
|
+
readonly credential: string;
|
|
107
|
+
readonly deploymentId: string;
|
|
108
|
+
}) => Effect.Effect<CmsBuildApplicationAdmission, CmsOutputDeploymentUnavailable>;
|
|
109
|
+
/** Internal trusted server lookup, intended for createCmsApplicationBuildSnapshots. */
|
|
110
|
+
readonly resolveApplication: (pin: CmsBuildSnapshotApplicationPin) => Promise<CmsBuildSnapshotPreparedApplication>;
|
|
111
|
+
/** Internal metadata lookup for server-owned asset providers. It returns no
|
|
112
|
+
* filesystem root and grants no read, execution or publication authority. */
|
|
113
|
+
readonly readApplication: (identity: Pick<CmsBuildSnapshotApplicationPin, 'inputsId' | 'executionId'>) => Promise<Omit<CmsBuildApplicationAdmission, 'deploymentId'>>;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export declare interface CmsBuildApplicationCatalogOptions {
|
|
117
|
+
readonly store: DataStore;
|
|
118
|
+
readonly scope: OutputActivationScope;
|
|
119
|
+
/** Server-owned receiver: verify the complete native application archive,
|
|
120
|
+
* compare the separately admitted pin, and recheck authorization at bounded
|
|
121
|
+
* IO boundaries and before making custody reopenable. Never import in host. */
|
|
122
|
+
readonly receive: (input: CmsBuildApplicationAdmission, bytes: AsyncIterable<Uint8Array>, authorize: () => Promise<void>, signal: AbortSignal) => Promise<CmsBuildSnapshotPreparedApplication>;
|
|
123
|
+
/** Fixed private archive roots. Every reopen verifies the original bytes;
|
|
124
|
+
* a catalog row alone never supplies an executable implementation. */
|
|
125
|
+
readonly open: (input: Omit<CmsBuildApplicationAdmission, 'deploymentId'>) => Promise<CmsBuildSnapshotPreparedApplication>;
|
|
126
|
+
/** Verify native archive custody without loading application declarations or
|
|
127
|
+
* executing code. The server fixes the storage root; the caller fixes only
|
|
128
|
+
* the original archive/pin comparison. */
|
|
129
|
+
readonly verify: (input: Omit<CmsBuildApplicationAdmission, 'deploymentId'>, authorize: () => Promise<void>, signal: AbortSignal) => Promise<void>;
|
|
130
|
+
readonly now?: () => number;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export declare const cmsBuildApplicationRest: (service: Pick<CmsBuildApplicationCatalog, "admit" | "inspect">, options: {
|
|
134
|
+
readonly maxBodyBytes: number;
|
|
135
|
+
}) => {
|
|
136
|
+
routes: {
|
|
137
|
+
guards: RestGuard[];
|
|
138
|
+
maxBodyBytes: number;
|
|
139
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
140
|
+
method: RestMethod;
|
|
141
|
+
path: string;
|
|
142
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
143
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
144
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
145
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
146
|
+
summary?: string;
|
|
147
|
+
description?: string;
|
|
148
|
+
example?: RestRouteExample;
|
|
149
|
+
operationId?: string;
|
|
150
|
+
tags?: ReadonlyArray<string>;
|
|
151
|
+
projection?: RestRouteProjection;
|
|
152
|
+
deprecated?: string;
|
|
153
|
+
sunset?: string;
|
|
154
|
+
version?: `v${number}`;
|
|
155
|
+
cors?: RestCors;
|
|
156
|
+
credentials?: "bearer";
|
|
157
|
+
rateLimit?: RestRateLimit;
|
|
158
|
+
streaming?: boolean;
|
|
159
|
+
etag?: boolean;
|
|
160
|
+
cache?: RestCache;
|
|
161
|
+
}[];
|
|
162
|
+
httpRoutes: (PluginHttpRoute | {
|
|
163
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
164
|
+
headers: {
|
|
165
|
+
'www-authenticate'?: string;
|
|
166
|
+
'cache-control': string;
|
|
167
|
+
pragma: string;
|
|
168
|
+
vary: string;
|
|
169
|
+
};
|
|
170
|
+
status: number;
|
|
171
|
+
body?: string | Uint8Array;
|
|
172
|
+
contentType?: string;
|
|
173
|
+
stream?: PluginHttpRouteStream;
|
|
174
|
+
cause?: unknown;
|
|
175
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
176
|
+
}>;
|
|
177
|
+
workload?: ApiWorkload;
|
|
178
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
179
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
180
|
+
answersOtherMethods?: boolean | undefined;
|
|
181
|
+
path: string;
|
|
182
|
+
match?: "prefix" | "exact";
|
|
183
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise<PluginHttpRouteResult>;
|
|
184
|
+
maxBodyBytes?: number;
|
|
185
|
+
originGuard?: "exempt";
|
|
186
|
+
cors?: RestCors;
|
|
187
|
+
credentials?: "bearer";
|
|
188
|
+
})[];
|
|
189
|
+
};
|
|
190
|
+
|
|
191
|
+
export declare class CmsBuildApplicationUploadUnavailable extends CmsBuildApplicationUploadUnavailable_base {
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
declare const CmsBuildApplicationUploadUnavailable_base: Schema.Class<CmsBuildApplicationUploadUnavailable, Schema.TaggedStruct<"CmsBuildApplicationUploadUnavailable", {
|
|
195
|
+
readonly reason: Schema.Literals<readonly ["input", "authority", "transfer", "response", "aborted"]>;
|
|
196
|
+
}>, YieldableError>;
|
|
197
|
+
|
|
198
|
+
/** An expected retained application is a comparison, never a provider selection. */
|
|
199
|
+
export declare interface CmsBuildSnapshotApplicationPin {
|
|
200
|
+
readonly code: SnapshotAppCodePin;
|
|
201
|
+
readonly inputsId: string;
|
|
202
|
+
readonly executionId: string;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
export declare interface CmsBuildSnapshotApplicationSource {
|
|
206
|
+
readonly format: 'voltro.app.build-inputs/v1';
|
|
207
|
+
readonly entries: () => Iterable<{
|
|
208
|
+
readonly key: string;
|
|
209
|
+
readonly value: Readonly<Record<string, unknown>>;
|
|
210
|
+
}> | AsyncIterable<{
|
|
211
|
+
readonly key: string;
|
|
212
|
+
readonly value: Readonly<Record<string, unknown>>;
|
|
213
|
+
}>;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
export declare interface CmsBuildSnapshotCaptureRequest {
|
|
217
|
+
readonly apiKey: string;
|
|
218
|
+
readonly attemptId: string;
|
|
219
|
+
readonly releaseId: string;
|
|
220
|
+
/** Refuse a different server-prepared application before creating an attempt. */
|
|
221
|
+
readonly expectedApplication?: CmsBuildSnapshotApplicationPin;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
export declare interface CmsBuildSnapshotGrant {
|
|
225
|
+
readonly id: string;
|
|
226
|
+
readonly token: string;
|
|
227
|
+
readonly expiresAt: number;
|
|
228
|
+
readonly consumerId: string;
|
|
229
|
+
readonly buildId: string;
|
|
230
|
+
readonly snapshotId: string;
|
|
231
|
+
readonly snapshotDigest: string;
|
|
232
|
+
/** Bounded catalog from the same independently verified retained app.
|
|
233
|
+
* This describes public presentation classes, never a person's consent. */
|
|
234
|
+
readonly consentPurposes: ReadonlyArray<SnapshotConsentPurpose>;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
export declare interface CmsBuildSnapshotOpenRequest {
|
|
238
|
+
readonly apiKey: string;
|
|
239
|
+
readonly snapshot: CmsBuildSnapshotPin;
|
|
240
|
+
/** Original grant proof plus freshly authenticated same-parent credential. */
|
|
241
|
+
readonly resume?: {
|
|
242
|
+
readonly token: string;
|
|
243
|
+
readonly buildId: string;
|
|
244
|
+
};
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
export declare interface CmsBuildSnapshotPin {
|
|
248
|
+
readonly id: string;
|
|
249
|
+
readonly digest: string;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
export declare interface CmsBuildSnapshotPreparedApplication extends CmsBuildSnapshotApplicationPin {
|
|
253
|
+
readonly app: CmsBuildSnapshotApplicationSource;
|
|
254
|
+
readonly execution: SnapshotAppExecution;
|
|
255
|
+
readonly routeDiscovery: unknown;
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
export declare interface CmsBuildSnapshotReadRequest {
|
|
259
|
+
readonly snapshot: CmsBuildSnapshotPin;
|
|
260
|
+
readonly token: string;
|
|
261
|
+
readonly consumerId: string;
|
|
262
|
+
readonly buildId: string;
|
|
263
|
+
readonly host: string;
|
|
264
|
+
readonly path: string;
|
|
265
|
+
readonly presentation?: SnapshotPresentation;
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
export declare interface CmsBuildSnapshotRedirectOutput {
|
|
269
|
+
readonly artifactId: string;
|
|
270
|
+
readonly count: number;
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
export declare type CmsBuildSnapshotRedirectRequest = CmsBuildSnapshotSafetyRequest & {
|
|
274
|
+
readonly safety: {
|
|
275
|
+
readonly artifactId: string;
|
|
276
|
+
};
|
|
277
|
+
readonly targets: ReadonlyArray<SnapshotRedirectTargetDocuments>;
|
|
278
|
+
};
|
|
279
|
+
|
|
280
|
+
export declare interface CmsBuildSnapshotRendered {
|
|
281
|
+
readonly html: string;
|
|
282
|
+
readonly head: string;
|
|
283
|
+
/** Complete private document for a retained production web build, otherwise null. */
|
|
284
|
+
readonly document: string | null;
|
|
285
|
+
/** Private artifact identity, never permission to activate or serve it. */
|
|
286
|
+
readonly artifactId: string | null;
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
/** Mount httpRoutes through the existing raw plugin HTTP seam. Pass routes to
|
|
290
|
+
* openapiPlugin for the exact same schemas. Do not also register routes in the
|
|
291
|
+
* app's generic restRoutes collection: its authentication and idempotency cache
|
|
292
|
+
* are separate from this scoped credential exchange and can cache grant tokens.
|
|
293
|
+
* The service verifies every credential; no Subject supplied by HTTP grants it
|
|
294
|
+
* authority. There is no ambient live-content or general database capability. */
|
|
295
|
+
export declare const cmsBuildSnapshotRest: (service: CmsBuildSnapshots) => {
|
|
296
|
+
routes: {
|
|
297
|
+
guards: RestGuard[];
|
|
298
|
+
maxBodyBytes: number;
|
|
299
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
300
|
+
method: RestMethod;
|
|
301
|
+
path: string;
|
|
302
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
303
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
304
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
305
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
306
|
+
summary?: string;
|
|
307
|
+
description?: string;
|
|
308
|
+
example?: RestRouteExample;
|
|
309
|
+
operationId?: string;
|
|
310
|
+
tags?: ReadonlyArray<string>;
|
|
311
|
+
projection?: RestRouteProjection;
|
|
312
|
+
deprecated?: string;
|
|
313
|
+
sunset?: string;
|
|
314
|
+
version?: `v${number}`;
|
|
315
|
+
cors?: RestCors;
|
|
316
|
+
credentials?: "bearer";
|
|
317
|
+
rateLimit?: RestRateLimit;
|
|
318
|
+
streaming?: boolean;
|
|
319
|
+
etag?: boolean;
|
|
320
|
+
cache?: RestCache;
|
|
321
|
+
}[];
|
|
322
|
+
httpRoutes: {
|
|
323
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
324
|
+
headers: {
|
|
325
|
+
'www-authenticate'?: string;
|
|
326
|
+
'cache-control': string;
|
|
327
|
+
pragma: string;
|
|
328
|
+
vary: string;
|
|
329
|
+
};
|
|
330
|
+
status: number;
|
|
331
|
+
body?: string | Uint8Array;
|
|
332
|
+
contentType?: string;
|
|
333
|
+
stream?: PluginHttpRouteStream;
|
|
334
|
+
cause?: unknown;
|
|
335
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
336
|
+
}>;
|
|
337
|
+
workload?: ApiWorkload;
|
|
338
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
339
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
340
|
+
answersOtherMethods?: boolean | undefined;
|
|
341
|
+
path: string;
|
|
342
|
+
match?: "prefix" | "exact";
|
|
343
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
344
|
+
maxBodyBytes?: number;
|
|
345
|
+
originGuard?: "exempt";
|
|
346
|
+
cors?: RestCors;
|
|
347
|
+
credentials?: "bearer";
|
|
348
|
+
}[];
|
|
349
|
+
};
|
|
350
|
+
|
|
351
|
+
export declare interface CmsBuildSnapshots {
|
|
352
|
+
readonly capture: (request: CmsBuildSnapshotCaptureRequest) => Effect.Effect<CmsBuildSnapshotPin & {
|
|
353
|
+
readonly expiresAt: number;
|
|
354
|
+
}, CmsBuildSnapshotUnavailable>;
|
|
355
|
+
readonly open: (request: CmsBuildSnapshotOpenRequest) => Effect.Effect<CmsBuildSnapshotGrant, CmsBuildSnapshotUnavailable>;
|
|
356
|
+
readonly read: (request: CmsBuildSnapshotReadRequest) => Effect.Effect<SnapshotRouteRead | null, CmsBuildSnapshotUnavailable>;
|
|
357
|
+
readonly readBinding: (request: CmsBuildSnapshotReadRequest & {
|
|
358
|
+
readonly binding: string;
|
|
359
|
+
}) => Effect.Effect<SnapshotBindingRead | null, CmsBuildSnapshotUnavailable>;
|
|
360
|
+
readonly readTree: (request: CmsBuildSnapshotReadRequest & {
|
|
361
|
+
readonly name: string;
|
|
362
|
+
}) => Effect.Effect<SnapshotTreeData, CmsBuildSnapshotUnavailable>;
|
|
363
|
+
readonly render: (request: CmsBuildSnapshotReadRequest) => Effect.Effect<CmsBuildSnapshotRendered | null, CmsBuildSnapshotUnavailable>;
|
|
364
|
+
readonly renderSafety: (request: CmsBuildSnapshotSafetyRequest) => Effect.Effect<CmsBuildSnapshotSafetyOutput, CmsBuildSnapshotUnavailable>;
|
|
365
|
+
readonly renderRedirects: (request: CmsBuildSnapshotRedirectRequest) => Effect.Effect<CmsBuildSnapshotRedirectOutput, CmsBuildSnapshotUnavailable>;
|
|
366
|
+
readonly renderSeo: (request: CmsBuildSnapshotSeoRequest) => Effect.Effect<CmsBuildSnapshotSeoOutput, CmsBuildSnapshotUnavailable>;
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
export declare interface CmsBuildSnapshotSafetyOutput {
|
|
370
|
+
readonly artifactId: string;
|
|
371
|
+
readonly generation: number;
|
|
372
|
+
readonly entryCount: number;
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
export declare type CmsBuildSnapshotSafetyRequest = Omit<CmsBuildSnapshotReadRequest, 'path' | 'presentation'> & {
|
|
376
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
377
|
+
};
|
|
378
|
+
|
|
379
|
+
export declare interface CmsBuildSnapshotSeoOutput {
|
|
380
|
+
readonly sitemapArtifactId: string;
|
|
381
|
+
readonly robotsArtifactId: string;
|
|
382
|
+
readonly urlCount: number;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
export declare type CmsBuildSnapshotSeoRequest = Omit<CmsBuildSnapshotReadRequest, 'path' | 'presentation'> & {
|
|
386
|
+
readonly documents?: SnapshotSeoDocumentsSelection;
|
|
387
|
+
readonly safety?: {
|
|
388
|
+
readonly artifactId: string;
|
|
389
|
+
};
|
|
390
|
+
};
|
|
391
|
+
|
|
392
|
+
export declare interface CmsBuildSnapshotsOptions {
|
|
393
|
+
readonly store: DataStore;
|
|
394
|
+
readonly scope: ChangeFeedScope;
|
|
395
|
+
/** Immutable server configuration, matching the retained application's definitions. */
|
|
396
|
+
readonly application: SnapshotCaptureApplicationDefinition;
|
|
397
|
+
readonly code: SnapshotAppCodePin;
|
|
398
|
+
/** Prepared before SQL capture: iteration must not execute application code. */
|
|
399
|
+
readonly app: CmsBuildSnapshotApplicationSource;
|
|
400
|
+
readonly routeDiscovery: unknown;
|
|
401
|
+
readonly execution: SnapshotAppExecution;
|
|
402
|
+
readonly custody: StorageCustodyShape;
|
|
403
|
+
readonly alias: string;
|
|
404
|
+
readonly requiredScope: string;
|
|
405
|
+
readonly snapshotTtlMs: number;
|
|
406
|
+
readonly maxMediaBytes: number;
|
|
407
|
+
readonly key: RenderReadKey;
|
|
408
|
+
readonly verificationKeys?: ReadonlyArray<RenderReadKey>;
|
|
409
|
+
readonly output?: {
|
|
410
|
+
readonly provider: SnapshotOutputProvider;
|
|
411
|
+
readonly use: SnapshotMediaUse;
|
|
412
|
+
readonly maxBytes: number;
|
|
413
|
+
};
|
|
414
|
+
readonly now?: () => number;
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
/** Add these server-only records to the API schema alongside the CMS content,
|
|
418
|
+
* publication/site/asset tables and the configured storage plugin's tables.
|
|
419
|
+
* They contain private state and are never a public delivery projection. */
|
|
420
|
+
export declare const cmsBuildSnapshotTables: ReadonlyArray<TableLike>;
|
|
421
|
+
|
|
422
|
+
/** Closed boundary error: never serializes a database/provider error or input. */
|
|
423
|
+
export declare class CmsBuildSnapshotUnavailable extends CmsBuildSnapshotUnavailable_base {
|
|
424
|
+
}
|
|
425
|
+
|
|
426
|
+
declare const CmsBuildSnapshotUnavailable_base: Schema.Class<CmsBuildSnapshotUnavailable, Schema.TaggedStruct<"CmsBuildSnapshotUnavailable", {
|
|
427
|
+
readonly reason: Schema.Literals<readonly ["configuration", "credential", "capture", "grant", "read", "render"]>;
|
|
428
|
+
}>, YieldableError>;
|
|
429
|
+
|
|
430
|
+
/** Dedicated render-read bearer exchange. Mount only httpRoutes in the raw
|
|
431
|
+
* plugin HTTP seam and use routes for OpenAPI/client generation. The existing
|
|
432
|
+
* private/no-store transport never caches authority or borrows a Subject. */
|
|
433
|
+
export declare const cmsDocumentAssemblyRest: (service: ReturnType<typeof createSnapshotDocumentAssembly>) => {
|
|
434
|
+
routes: {
|
|
435
|
+
guards: RestGuard[];
|
|
436
|
+
maxBodyBytes: number;
|
|
437
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
438
|
+
method: RestMethod;
|
|
439
|
+
path: string;
|
|
440
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
441
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
442
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
443
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
444
|
+
summary?: string;
|
|
445
|
+
description?: string;
|
|
446
|
+
example?: RestRouteExample;
|
|
447
|
+
operationId?: string;
|
|
448
|
+
tags?: ReadonlyArray<string>;
|
|
449
|
+
projection?: RestRouteProjection;
|
|
450
|
+
deprecated?: string;
|
|
451
|
+
sunset?: string;
|
|
452
|
+
version?: `v${number}`;
|
|
453
|
+
cors?: RestCors;
|
|
454
|
+
credentials?: "bearer";
|
|
455
|
+
rateLimit?: RestRateLimit;
|
|
456
|
+
streaming?: boolean;
|
|
457
|
+
etag?: boolean;
|
|
458
|
+
cache?: RestCache;
|
|
459
|
+
}[];
|
|
460
|
+
httpRoutes: {
|
|
461
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
462
|
+
headers: {
|
|
463
|
+
'www-authenticate'?: string;
|
|
464
|
+
'cache-control': string;
|
|
465
|
+
pragma: string;
|
|
466
|
+
vary: string;
|
|
467
|
+
};
|
|
468
|
+
status: number;
|
|
469
|
+
body?: string | Uint8Array;
|
|
470
|
+
contentType?: string;
|
|
471
|
+
stream?: PluginHttpRouteStream;
|
|
472
|
+
cause?: unknown;
|
|
473
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
474
|
+
}>;
|
|
475
|
+
workload?: ApiWorkload;
|
|
476
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
477
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
478
|
+
answersOtherMethods?: boolean | undefined;
|
|
479
|
+
path: string;
|
|
480
|
+
match?: "prefix" | "exact";
|
|
481
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
482
|
+
maxBodyBytes?: number;
|
|
483
|
+
originGuard?: "exempt";
|
|
484
|
+
cors?: RestCors;
|
|
485
|
+
credentials?: "bearer";
|
|
486
|
+
}[];
|
|
487
|
+
};
|
|
488
|
+
|
|
489
|
+
export declare interface CmsNativeOutputDeployments extends CmsOutputDeployments {
|
|
490
|
+
readonly prepare: (input: CmsOutputTargetPreparation) => Effect.Effect<RetainedOutputActivationTarget, CmsOutputDeploymentUnavailable>;
|
|
491
|
+
}
|
|
492
|
+
|
|
493
|
+
export declare interface CmsNativeOutputDeploymentsOptions {
|
|
494
|
+
readonly store: DataStore;
|
|
495
|
+
readonly scope: OutputActivationScope;
|
|
496
|
+
readonly key: RenderReadKey;
|
|
497
|
+
readonly verificationKeys?: ReadonlyArray<RenderReadKey>;
|
|
498
|
+
readonly pathKeys: ReadonlyArray<RenderReadKey>;
|
|
499
|
+
readonly quorum: number;
|
|
500
|
+
readonly regions: Readonly<Record<string, {
|
|
501
|
+
readonly key: RenderReadKey;
|
|
502
|
+
readonly verificationKeys?: ReadonlyArray<RenderReadKey>;
|
|
503
|
+
/** Fixed server roots: stage all six original roles, then reopen/rehash. */
|
|
504
|
+
readonly stage: (set: OutputActivationSet) => Promise<{
|
|
505
|
+
readonly outputId: string;
|
|
506
|
+
}>;
|
|
507
|
+
readonly verify: (set: OutputActivationSet, outputId: string) => Promise<void>;
|
|
508
|
+
readonly readArtifacts: (set: OutputActivationSet, outputId: string) => Promise<Omit<OutputRouteGraphArtifacts, 'pathSets'>>;
|
|
509
|
+
readonly readRoutes: (set: OutputActivationSet, outputId: string) => ReturnType<OutputActivationRouteInventory>;
|
|
510
|
+
}>>;
|
|
511
|
+
readonly use: (target: {
|
|
512
|
+
readonly host: string;
|
|
513
|
+
readonly path: string;
|
|
514
|
+
}) => SnapshotMediaUse;
|
|
515
|
+
readonly now?: () => number;
|
|
516
|
+
}
|
|
517
|
+
|
|
518
|
+
/** Private server records. Declare alongside the core, publication/site and
|
|
519
|
+
* snapshot tables. They must never become public delivery projections. */
|
|
520
|
+
export declare const cmsOutputActivationTables: ReadonlyArray<TableLike>;
|
|
521
|
+
|
|
522
|
+
export declare interface CmsOutputDeploymentCredential {
|
|
523
|
+
readonly credential: string;
|
|
524
|
+
}
|
|
525
|
+
|
|
526
|
+
export declare interface CmsOutputDeploymentRequest extends CmsOutputDeploymentCredential {
|
|
527
|
+
readonly targetId: string;
|
|
528
|
+
readonly expectedRevision: number;
|
|
529
|
+
readonly expectedGeneration: number;
|
|
530
|
+
readonly mode: 'forward' | 'rollback';
|
|
531
|
+
readonly outputs: ReadonlyArray<{
|
|
532
|
+
readonly region: string;
|
|
533
|
+
readonly outputId: string;
|
|
534
|
+
}>;
|
|
535
|
+
}
|
|
536
|
+
|
|
537
|
+
/** Mount only through the private raw HTTP seam. Every call independently
|
|
538
|
+
* verifies an organization API key with cms:deploy and exact server-owned scope.
|
|
539
|
+
* No ambient Subject, build credential, request-selected provider or signer. */
|
|
540
|
+
export declare const cmsOutputDeploymentRest: (service: CmsOutputDeployments) => {
|
|
541
|
+
routes: {
|
|
542
|
+
maxBodyBytes: number;
|
|
543
|
+
guards: RestGuard[];
|
|
544
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
545
|
+
method: RestMethod;
|
|
546
|
+
path: string;
|
|
547
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
548
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
549
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
550
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
551
|
+
summary?: string;
|
|
552
|
+
description?: string;
|
|
553
|
+
example?: RestRouteExample;
|
|
554
|
+
operationId?: string;
|
|
555
|
+
tags?: ReadonlyArray<string>;
|
|
556
|
+
projection?: RestRouteProjection;
|
|
557
|
+
deprecated?: string;
|
|
558
|
+
sunset?: string;
|
|
559
|
+
version?: `v${number}`;
|
|
560
|
+
cors?: RestCors;
|
|
561
|
+
credentials?: "bearer";
|
|
562
|
+
rateLimit?: RestRateLimit;
|
|
563
|
+
streaming?: boolean;
|
|
564
|
+
etag?: boolean;
|
|
565
|
+
cache?: RestCache;
|
|
566
|
+
}[];
|
|
567
|
+
httpRoutes: {
|
|
568
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
569
|
+
headers: {
|
|
570
|
+
'www-authenticate'?: string;
|
|
571
|
+
'cache-control': string;
|
|
572
|
+
pragma: string;
|
|
573
|
+
vary: string;
|
|
574
|
+
};
|
|
575
|
+
status: number;
|
|
576
|
+
body?: string | Uint8Array;
|
|
577
|
+
contentType?: string;
|
|
578
|
+
stream?: PluginHttpRouteStream;
|
|
579
|
+
cause?: unknown;
|
|
580
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
581
|
+
}>;
|
|
582
|
+
workload?: ApiWorkload;
|
|
583
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
584
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
585
|
+
answersOtherMethods?: boolean | undefined;
|
|
586
|
+
path: string;
|
|
587
|
+
match?: "prefix" | "exact";
|
|
588
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
589
|
+
maxBodyBytes?: number;
|
|
590
|
+
originGuard?: "exempt";
|
|
591
|
+
cors?: RestCors;
|
|
592
|
+
credentials?: "bearer";
|
|
593
|
+
}[];
|
|
594
|
+
};
|
|
595
|
+
|
|
596
|
+
export declare interface CmsOutputDeploymentResult {
|
|
597
|
+
readonly deployment: OutputDeployment;
|
|
598
|
+
readonly activation: OutputActivationMarker;
|
|
599
|
+
}
|
|
600
|
+
|
|
601
|
+
export declare interface CmsOutputDeployments {
|
|
602
|
+
readonly inspect: (input: CmsOutputDeploymentCredential) => Effect.Effect<{
|
|
603
|
+
readonly revision: number;
|
|
604
|
+
readonly generation: number;
|
|
605
|
+
}, CmsOutputDeploymentUnavailable>;
|
|
606
|
+
readonly deploy: (input: CmsOutputDeploymentRequest) => Effect.Effect<CmsOutputDeploymentResult, CmsOutputDeploymentUnavailable>;
|
|
607
|
+
/** Confirm this exact current result without staging, binding or activating. */
|
|
608
|
+
readonly confirm: (input: CmsOutputDeploymentRequest) => Effect.Effect<CmsOutputDeploymentResult, CmsOutputDeploymentUnavailable>;
|
|
609
|
+
readonly bind: (input: CmsOutputDeploymentCredential & {
|
|
610
|
+
readonly deploymentId: string;
|
|
611
|
+
readonly expectedRevision: number;
|
|
612
|
+
}) => Effect.Effect<OutputDeployment, CmsOutputDeploymentUnavailable>;
|
|
613
|
+
readonly probe: (input: CmsOutputDeploymentCredential & {
|
|
614
|
+
readonly targetId: string;
|
|
615
|
+
readonly expectedGeneration: number;
|
|
616
|
+
readonly mode: 'forward' | 'rollback';
|
|
617
|
+
}) => Effect.Effect<OutputActivationProbe, CmsOutputDeploymentUnavailable>;
|
|
618
|
+
readonly observeRegion: (input: CmsOutputDeploymentCredential & {
|
|
619
|
+
readonly targetId: string;
|
|
620
|
+
readonly probe: OutputActivationProbe;
|
|
621
|
+
readonly region: string;
|
|
622
|
+
readonly outputId: string;
|
|
623
|
+
}) => Effect.Effect<OutputRegionReceipt, CmsOutputDeploymentUnavailable>;
|
|
624
|
+
readonly activate: (input: CmsOutputDeploymentCredential & {
|
|
625
|
+
readonly targetId: string;
|
|
626
|
+
readonly probe: OutputActivationProbe;
|
|
627
|
+
readonly receipts: ReadonlyArray<OutputRegionReceipt>;
|
|
628
|
+
}) => Effect.Effect<OutputActivationMarker, CmsOutputDeploymentUnavailable>;
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
export declare interface CmsOutputDeploymentsOptions {
|
|
632
|
+
readonly store: DataStore;
|
|
633
|
+
readonly scope: OutputActivationScope;
|
|
634
|
+
readonly key: RenderReadKey;
|
|
635
|
+
readonly verificationKeys?: ReadonlyArray<RenderReadKey>;
|
|
636
|
+
/** Server-owned original deployment admission, not request-supplied contracts. */
|
|
637
|
+
readonly readDeployment: (tx: DataStore, deploymentId: string) => Promise<{
|
|
638
|
+
readonly app: OutputActivationManifest['app'];
|
|
639
|
+
readonly renderPolicyDigest: string;
|
|
640
|
+
}>;
|
|
641
|
+
/** Server-owned target custody; HTTP supplies only its content identity. */
|
|
642
|
+
readonly readSet: (tx: DataStore, targetId: string) => Promise<OutputActivationSet>;
|
|
643
|
+
readonly admit: OutputActivationAdmission;
|
|
644
|
+
readonly readRoutes: OutputActivationRouteInventory;
|
|
645
|
+
readonly regions: Readonly<Record<string, {
|
|
646
|
+
readonly key: RenderReadKey;
|
|
647
|
+
readonly verificationKeys?: ReadonlyArray<RenderReadKey>;
|
|
648
|
+
/** Rehash every role/file in this exact physical output and target. */
|
|
649
|
+
readonly verify: (tx: DataStore, set: OutputActivationSet, outputId: string) => Promise<void>;
|
|
650
|
+
}>>;
|
|
651
|
+
readonly now?: () => number;
|
|
652
|
+
}
|
|
653
|
+
|
|
654
|
+
export declare class CmsOutputDeploymentUnavailable extends CmsOutputDeploymentUnavailable_base {
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
declare const CmsOutputDeploymentUnavailable_base: Schema.Class<CmsOutputDeploymentUnavailable, Schema.TaggedStruct<"CmsOutputDeploymentUnavailable", {
|
|
658
|
+
readonly reason: Schema.Literals<readonly ["configuration", "credential", "input", "integrity", "state", "changed", "generation", "regions", "denied", "expired", "unadmitted"]>;
|
|
659
|
+
}>, YieldableError>;
|
|
660
|
+
|
|
661
|
+
export declare interface CmsOutputTargetPreparation extends CmsOutputDeploymentCredential {
|
|
662
|
+
readonly deploymentId: string;
|
|
663
|
+
readonly snapshot: {
|
|
664
|
+
readonly id: string;
|
|
665
|
+
readonly digest: string;
|
|
666
|
+
};
|
|
667
|
+
readonly pathSets: ReadonlyArray<{
|
|
668
|
+
readonly host: string;
|
|
669
|
+
readonly jobId: string;
|
|
670
|
+
readonly digest: string;
|
|
671
|
+
}>;
|
|
672
|
+
readonly artifacts: OutputActivationManifest['artifacts'];
|
|
673
|
+
}
|
|
674
|
+
|
|
675
|
+
export declare const cmsOutputTargetRest: (service: Pick<CmsNativeOutputDeployments, "prepare">) => {
|
|
676
|
+
routes: {
|
|
677
|
+
maxBodyBytes: number;
|
|
678
|
+
guards: RestGuard[];
|
|
679
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
680
|
+
method: RestMethod;
|
|
681
|
+
path: string;
|
|
682
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
683
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
684
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
685
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
686
|
+
summary?: string;
|
|
687
|
+
description?: string;
|
|
688
|
+
example?: RestRouteExample;
|
|
689
|
+
operationId?: string;
|
|
690
|
+
tags?: ReadonlyArray<string>;
|
|
691
|
+
projection?: RestRouteProjection;
|
|
692
|
+
deprecated?: string;
|
|
693
|
+
sunset?: string;
|
|
694
|
+
version?: `v${number}`;
|
|
695
|
+
cors?: RestCors;
|
|
696
|
+
credentials?: "bearer";
|
|
697
|
+
rateLimit?: RestRateLimit;
|
|
698
|
+
streaming?: boolean;
|
|
699
|
+
etag?: boolean;
|
|
700
|
+
cache?: RestCache;
|
|
701
|
+
}[];
|
|
702
|
+
httpRoutes: {
|
|
703
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
704
|
+
headers: {
|
|
705
|
+
'www-authenticate'?: string;
|
|
706
|
+
'cache-control': string;
|
|
707
|
+
pragma: string;
|
|
708
|
+
vary: string;
|
|
709
|
+
};
|
|
710
|
+
status: number;
|
|
711
|
+
body?: string | Uint8Array;
|
|
712
|
+
contentType?: string;
|
|
713
|
+
stream?: PluginHttpRouteStream;
|
|
714
|
+
cause?: unknown;
|
|
715
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
716
|
+
}>;
|
|
717
|
+
workload?: ApiWorkload;
|
|
718
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
719
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
720
|
+
answersOtherMethods?: boolean | undefined;
|
|
721
|
+
path: string;
|
|
722
|
+
match?: "prefix" | "exact";
|
|
723
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
724
|
+
maxBodyBytes?: number;
|
|
725
|
+
originGuard?: "exempt";
|
|
726
|
+
cors?: RestCors;
|
|
727
|
+
credentials?: "bearer";
|
|
728
|
+
}[];
|
|
729
|
+
};
|
|
730
|
+
|
|
731
|
+
export declare interface CmsPublicBuildIdentity {
|
|
732
|
+
readonly version: 1;
|
|
733
|
+
readonly snapshotDigest: string;
|
|
734
|
+
readonly inputsId: string;
|
|
735
|
+
readonly executionId: string;
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
export declare interface CmsPublicBuildPage<T = unknown> {
|
|
739
|
+
readonly version: 1;
|
|
740
|
+
readonly build: CmsPublicBuildIdentity;
|
|
741
|
+
readonly path: string;
|
|
742
|
+
readonly page: T;
|
|
743
|
+
}
|
|
744
|
+
|
|
745
|
+
/** Resolve the host through the application's trusted proxy/domain policy.
|
|
746
|
+
* Request query parameters cannot choose tenant/site/environment or origin. */
|
|
747
|
+
export declare const cmsPublicBuildRest: (service: CmsPublicBuilds, options: {
|
|
748
|
+
readonly host: (headers: Readonly<Record<string, string>>) => string;
|
|
749
|
+
readonly choices?: (headers: Readonly<Record<string, string>>) => ConsentChoices | undefined;
|
|
750
|
+
}) => {
|
|
751
|
+
routes: RestRouteDescriptor<Record<string, unknown>, unknown>[];
|
|
752
|
+
httpRoutes: {
|
|
753
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
754
|
+
headers: {
|
|
755
|
+
'cache-control': string;
|
|
756
|
+
pragma: string;
|
|
757
|
+
vary: string;
|
|
758
|
+
};
|
|
759
|
+
status: number;
|
|
760
|
+
body?: string | Uint8Array;
|
|
761
|
+
contentType?: string;
|
|
762
|
+
stream?: PluginHttpRouteStream;
|
|
763
|
+
cause?: unknown;
|
|
764
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
765
|
+
}>;
|
|
766
|
+
workload?: ApiWorkload;
|
|
767
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
768
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
769
|
+
answersOtherMethods?: boolean | undefined;
|
|
770
|
+
path: string;
|
|
771
|
+
match?: "prefix" | "exact";
|
|
772
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
773
|
+
maxBodyBytes?: number;
|
|
774
|
+
originGuard?: "exempt";
|
|
775
|
+
cors?: RestCors;
|
|
776
|
+
credentials?: "bearer";
|
|
777
|
+
}[];
|
|
778
|
+
};
|
|
779
|
+
|
|
780
|
+
export declare interface CmsPublicBuilds {
|
|
781
|
+
readonly page: (input: {
|
|
782
|
+
readonly build: CmsPublicBuildIdentity;
|
|
783
|
+
readonly host: string;
|
|
784
|
+
readonly path: string;
|
|
785
|
+
readonly choices?: ConsentChoices;
|
|
786
|
+
}) => Effect.Effect<CmsPublicBuildPage, CmsPublicBuildUnavailable>;
|
|
787
|
+
}
|
|
788
|
+
|
|
789
|
+
export declare interface CmsPublicBuildsOptions {
|
|
790
|
+
readonly store: DataStore;
|
|
791
|
+
readonly scope: OutputActivationScope;
|
|
792
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
793
|
+
readonly regionKeys: Readonly<Record<string, ReadonlyArray<RenderReadKey>>>;
|
|
794
|
+
readonly region: string;
|
|
795
|
+
readonly admit: OutputServingAdmission;
|
|
796
|
+
/** Trusted artifact adapter: select only the serialized public presentation
|
|
797
|
+
* produced with this exact document/route. Rehash physical custody and reject
|
|
798
|
+
* unknown targets. Never implement this with a live delivery query. */
|
|
799
|
+
/** Verify the captured policy and complete class inventory in this exact region. */
|
|
800
|
+
readonly readPresentations: (tx: DataStore, set: OutputActivationSet, receipt: OutputRegionReceipt) => Promise<CmsPublicPresentations>;
|
|
801
|
+
readonly readPage: (tx: DataStore, set: OutputActivationSet, receipt: OutputRegionReceipt, target: CmsPublicPresentationTarget) => Promise<{
|
|
802
|
+
readonly found: false;
|
|
803
|
+
} | {
|
|
804
|
+
readonly found: true;
|
|
805
|
+
readonly page: unknown;
|
|
806
|
+
}>;
|
|
807
|
+
}
|
|
808
|
+
|
|
809
|
+
declare class CmsPublicBuildUnavailable extends Error {
|
|
810
|
+
readonly reason: 'identity' | 'request' | 'changed' | 'not-found' | 'denied' | 'transport';
|
|
811
|
+
readonly _tag = "CmsPublicBuildUnavailable";
|
|
812
|
+
constructor(reason: 'identity' | 'request' | 'changed' | 'not-found' | 'denied' | 'transport');
|
|
813
|
+
}
|
|
814
|
+
|
|
815
|
+
/** Current server admission for a private render using an already-public
|
|
816
|
+
* document. Compare the whole pin before and after rendering; no HTTP route
|
|
817
|
+
* publishes it and it grants no mutation or private CMS read authority. */
|
|
818
|
+
export declare interface CmsPublicDocumentAdmission {
|
|
819
|
+
readonly setId: string;
|
|
820
|
+
readonly generation: number;
|
|
821
|
+
readonly safetyGeneration: number;
|
|
822
|
+
readonly region: string;
|
|
823
|
+
readonly outputId: string;
|
|
824
|
+
readonly snapshotDigest: string;
|
|
825
|
+
readonly app: OutputActivationSet['manifest']['app'];
|
|
826
|
+
readonly target: CmsPublicPresentationTarget;
|
|
827
|
+
}
|
|
828
|
+
|
|
829
|
+
export declare interface CmsPublicOutputAsset extends CmsPublicOutputFile {
|
|
830
|
+
readonly uses: ReadonlyArray<{
|
|
831
|
+
readonly documentUrl: string;
|
|
832
|
+
readonly rights: unknown;
|
|
833
|
+
readonly presentation: SnapshotPresentation;
|
|
834
|
+
}>;
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
export declare interface CmsPublicOutputControl extends CmsPublicOutputFile {
|
|
838
|
+
/** Verified generation of the same receipted region's complete deny role. */
|
|
839
|
+
readonly safetyGeneration: number;
|
|
840
|
+
readonly uses: ReadonlyArray<{
|
|
841
|
+
readonly documentUrl: string;
|
|
842
|
+
readonly media: CmsPublicOutputDocument['media'];
|
|
843
|
+
}>;
|
|
844
|
+
}
|
|
845
|
+
|
|
846
|
+
export declare interface CmsPublicOutputDocument extends CmsPublicOutputFile {
|
|
847
|
+
/** Invoke only for the page-only transport, after current document admission. */
|
|
848
|
+
readonly projectPage: () => unknown;
|
|
849
|
+
/** Verified provider-specific presentation provenance. Kept server-side. */
|
|
850
|
+
readonly source?: unknown;
|
|
851
|
+
readonly media: ReadonlyArray<{
|
|
852
|
+
readonly digest: string;
|
|
853
|
+
readonly rights: unknown;
|
|
854
|
+
}>;
|
|
855
|
+
}
|
|
856
|
+
|
|
857
|
+
export declare interface CmsPublicOutputFile {
|
|
858
|
+
readonly bytes: Uint8Array;
|
|
859
|
+
readonly digest: string;
|
|
860
|
+
readonly contentType: string;
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
/** Explicit public document mounts preserve the application's API/auth routes.
|
|
864
|
+
* These mounts serve the anonymous captured basis, never personalized content. */
|
|
865
|
+
export declare const cmsPublicOutputHttp: (service: Pick<CmsPublicOutputs, "document" | "asset" | "control"> & Partial<Pick<CmsPublicOutputs, "redirect">>, options: {
|
|
866
|
+
readonly host: (headers: Readonly<Record<string, string>>) => string;
|
|
867
|
+
readonly choices?: (headers: Readonly<Record<string, string>>) => ConsentChoices | undefined;
|
|
868
|
+
readonly documents: ReadonlyArray<{
|
|
869
|
+
readonly path: string;
|
|
870
|
+
readonly match: "prefix" | "exact";
|
|
871
|
+
}>;
|
|
872
|
+
/** Explicitly reserve sitemap.xml, robots.txt and the sitemap shard directory. */
|
|
873
|
+
readonly controls?: boolean;
|
|
874
|
+
/** Resolve approved redirects before document reads, including explicit
|
|
875
|
+
* method-preserving non-GET responses on these document mounts. */
|
|
876
|
+
readonly redirects?: boolean;
|
|
877
|
+
}) => ReadonlyArray<PluginHttpRoute>;
|
|
878
|
+
|
|
879
|
+
export declare interface CmsPublicOutputRedirect {
|
|
880
|
+
readonly status: 301 | 302 | 307 | 308 | 404 | 410;
|
|
881
|
+
readonly location: string | null;
|
|
882
|
+
}
|
|
883
|
+
|
|
884
|
+
export declare interface CmsPublicOutputs extends CmsPublicBuilds {
|
|
885
|
+
readonly redirect: (input: {
|
|
886
|
+
readonly host: string;
|
|
887
|
+
readonly path: string;
|
|
888
|
+
readonly choices?: ConsentChoices;
|
|
889
|
+
}) => Effect.Effect<CmsPublicOutputRedirect, CmsPublicBuildUnavailable>;
|
|
890
|
+
readonly document: (input: {
|
|
891
|
+
readonly host: string;
|
|
892
|
+
readonly path: string;
|
|
893
|
+
readonly choices?: ConsentChoices;
|
|
894
|
+
}) => Effect.Effect<CmsPublicOutputFile, CmsPublicBuildUnavailable>;
|
|
895
|
+
/** Server-only source and current activation pin, with the same rights admission as document(). */
|
|
896
|
+
readonly admittedDocument: (input: {
|
|
897
|
+
readonly host: string;
|
|
898
|
+
readonly path: string;
|
|
899
|
+
readonly choices?: ConsentChoices;
|
|
900
|
+
}) => Effect.Effect<CmsAdmittedPublicDocument, CmsPublicBuildUnavailable>;
|
|
901
|
+
readonly asset: (input: {
|
|
902
|
+
readonly host: string;
|
|
903
|
+
readonly path: string;
|
|
904
|
+
readonly choices?: ConsentChoices;
|
|
905
|
+
}) => Effect.Effect<CmsPublicOutputFile, CmsPublicBuildUnavailable>;
|
|
906
|
+
readonly control: (input: {
|
|
907
|
+
readonly host: string;
|
|
908
|
+
readonly path: string;
|
|
909
|
+
}) => Effect.Effect<CmsPublicOutputFile, CmsPublicBuildUnavailable>;
|
|
910
|
+
}
|
|
911
|
+
|
|
912
|
+
export declare interface CmsPublicOutputsOptions extends Omit<CmsPublicBuildsOptions, 'readPage'> {
|
|
913
|
+
readonly use: (target: {
|
|
914
|
+
readonly host: string;
|
|
915
|
+
readonly path: string;
|
|
916
|
+
}) => SnapshotMediaUse;
|
|
917
|
+
readonly now?: () => number;
|
|
918
|
+
readonly readDocument: (tx: DataStore, set: OutputActivationSet, receipt: OutputRegionReceipt, target: CmsPublicPresentationTarget) => Promise<{
|
|
919
|
+
readonly found: false;
|
|
920
|
+
} | ({
|
|
921
|
+
readonly found: true;
|
|
922
|
+
} & CmsPublicOutputDocument)>;
|
|
923
|
+
readonly readAsset: (tx: DataStore, set: OutputActivationSet, receipt: OutputRegionReceipt, target: CmsPublicPresentationTarget) => Promise<{
|
|
924
|
+
readonly found: false;
|
|
925
|
+
} | ({
|
|
926
|
+
readonly found: true;
|
|
927
|
+
} & CmsPublicOutputAsset)>;
|
|
928
|
+
/** Exact verified redirect policy from this receipted region. Current
|
|
929
|
+
* ownership, intent, target admission and media rights are checked here. */
|
|
930
|
+
readonly readRedirect?: (tx: DataStore, set: OutputActivationSet, receipt: OutputRegionReceipt, target: {
|
|
931
|
+
readonly host: string;
|
|
932
|
+
readonly path: string;
|
|
933
|
+
}) => Promise<{
|
|
934
|
+
readonly found: false;
|
|
935
|
+
} | {
|
|
936
|
+
readonly found: true;
|
|
937
|
+
readonly definition: unknown;
|
|
938
|
+
readonly safetyGeneration: number;
|
|
939
|
+
}>;
|
|
940
|
+
/** Verified selected sitemap/robots bytes from this exact physical region.
|
|
941
|
+
* Absence leaves control serving disabled; private policy has no projection. */
|
|
942
|
+
readonly readControl?: (tx: DataStore, set: OutputActivationSet, receipt: OutputRegionReceipt, target: {
|
|
943
|
+
readonly host: string;
|
|
944
|
+
readonly path: string;
|
|
945
|
+
}) => Promise<{
|
|
946
|
+
readonly found: false;
|
|
947
|
+
} | ({
|
|
948
|
+
readonly found: true;
|
|
949
|
+
} & CmsPublicOutputControl)>;
|
|
950
|
+
}
|
|
951
|
+
|
|
952
|
+
export declare interface CmsPublicPresentations {
|
|
953
|
+
readonly consentPurposes: ReadonlyArray<SnapshotConsentPurpose>;
|
|
954
|
+
readonly presentations: ReadonlyArray<SnapshotPresentation>;
|
|
955
|
+
}
|
|
956
|
+
|
|
957
|
+
export declare interface CmsPublicPresentationTarget {
|
|
958
|
+
readonly host: string;
|
|
959
|
+
readonly path: string;
|
|
960
|
+
readonly presentation: SnapshotPresentation;
|
|
961
|
+
}
|
|
962
|
+
|
|
963
|
+
/** Use actual registered content types, approved site profiles and retained
|
|
964
|
+
* native discovery from the server application, never request-authored JSON. */
|
|
965
|
+
declare interface CmsPublicRouteDeclaration {
|
|
966
|
+
readonly types: ReadonlyArray<ContentType>;
|
|
967
|
+
readonly site: SiteDeliveryDefinition;
|
|
968
|
+
/** Explicit null admits only CMS locations, with no native routing/discovery. */
|
|
969
|
+
readonly code: SnapshotAppCodePin | null;
|
|
970
|
+
readonly routing: SnapshotRoutingDefinition | null;
|
|
971
|
+
readonly routeDiscovery: unknown;
|
|
972
|
+
}
|
|
973
|
+
|
|
974
|
+
/**
|
|
975
|
+
* Where a content row lives besides its tenant: the site it belongs to, the
|
|
976
|
+
* content environment (e.g. `production`, `staging`) and its locale. Three
|
|
977
|
+
* separate axes, stored on every draft, published row and revision, and
|
|
978
|
+
* required by every write and read — never taken from a caller's free-form
|
|
979
|
+
* filter. The tenant comes from the request subject (`tenant()`).
|
|
980
|
+
*/
|
|
981
|
+
declare interface CmsScope {
|
|
982
|
+
readonly site: string;
|
|
983
|
+
readonly environment: string;
|
|
984
|
+
/** A BCP 47 tag, e.g. `en-GB`. */
|
|
985
|
+
readonly locale: string;
|
|
986
|
+
}
|
|
987
|
+
|
|
988
|
+
/** Dedicated private composition. No archive/output path, web pin, arbitrary
|
|
989
|
+
* file name or activation authority can be supplied through the request. */
|
|
990
|
+
export declare const cmsSnapshotAssetsRest: (service: ReturnType<typeof createSnapshotAssetAssembly>) => {
|
|
991
|
+
routes: {
|
|
992
|
+
guards: RestGuard[];
|
|
993
|
+
maxBodyBytes: number;
|
|
994
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
995
|
+
method: RestMethod;
|
|
996
|
+
path: string;
|
|
997
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
998
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
999
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
1000
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
1001
|
+
summary?: string;
|
|
1002
|
+
description?: string;
|
|
1003
|
+
example?: RestRouteExample;
|
|
1004
|
+
operationId?: string;
|
|
1005
|
+
tags?: ReadonlyArray<string>;
|
|
1006
|
+
projection?: RestRouteProjection;
|
|
1007
|
+
deprecated?: string;
|
|
1008
|
+
sunset?: string;
|
|
1009
|
+
version?: `v${number}`;
|
|
1010
|
+
cors?: RestCors;
|
|
1011
|
+
credentials?: "bearer";
|
|
1012
|
+
rateLimit?: RestRateLimit;
|
|
1013
|
+
streaming?: boolean;
|
|
1014
|
+
etag?: boolean;
|
|
1015
|
+
cache?: RestCache;
|
|
1016
|
+
}[];
|
|
1017
|
+
httpRoutes: {
|
|
1018
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
1019
|
+
headers: {
|
|
1020
|
+
'www-authenticate'?: string;
|
|
1021
|
+
'cache-control': string;
|
|
1022
|
+
pragma: string;
|
|
1023
|
+
vary: string;
|
|
1024
|
+
};
|
|
1025
|
+
status: number;
|
|
1026
|
+
body?: string | Uint8Array;
|
|
1027
|
+
contentType?: string;
|
|
1028
|
+
stream?: PluginHttpRouteStream;
|
|
1029
|
+
cause?: unknown;
|
|
1030
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
1031
|
+
}>;
|
|
1032
|
+
workload?: ApiWorkload;
|
|
1033
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
1034
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
1035
|
+
answersOtherMethods?: boolean | undefined;
|
|
1036
|
+
path: string;
|
|
1037
|
+
match?: "prefix" | "exact";
|
|
1038
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
1039
|
+
maxBodyBytes?: number;
|
|
1040
|
+
originGuard?: "exempt";
|
|
1041
|
+
cors?: RestCors;
|
|
1042
|
+
credentials?: "bearer";
|
|
1043
|
+
}[];
|
|
1044
|
+
};
|
|
1045
|
+
|
|
1046
|
+
/** Private read-only transport. Base64 encodes at most 64KiB per chunk; no
|
|
1047
|
+
* request can select a filesystem root, another role or publisher authority. */
|
|
1048
|
+
export declare const cmsSnapshotDocumentTransferRest: (service: ReturnType<typeof createSnapshotDocumentTransfer>) => {
|
|
1049
|
+
routes: {
|
|
1050
|
+
guards: RestGuard[];
|
|
1051
|
+
maxBodyBytes: number;
|
|
1052
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
1053
|
+
method: RestMethod;
|
|
1054
|
+
path: string;
|
|
1055
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
1056
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
1057
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
1058
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
1059
|
+
summary?: string;
|
|
1060
|
+
description?: string;
|
|
1061
|
+
example?: RestRouteExample;
|
|
1062
|
+
operationId?: string;
|
|
1063
|
+
tags?: ReadonlyArray<string>;
|
|
1064
|
+
projection?: RestRouteProjection;
|
|
1065
|
+
deprecated?: string;
|
|
1066
|
+
sunset?: string;
|
|
1067
|
+
version?: `v${number}`;
|
|
1068
|
+
cors?: RestCors;
|
|
1069
|
+
credentials?: "bearer";
|
|
1070
|
+
rateLimit?: RestRateLimit;
|
|
1071
|
+
streaming?: boolean;
|
|
1072
|
+
etag?: boolean;
|
|
1073
|
+
cache?: RestCache;
|
|
1074
|
+
}[];
|
|
1075
|
+
httpRoutes: {
|
|
1076
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
1077
|
+
headers: {
|
|
1078
|
+
'www-authenticate'?: string;
|
|
1079
|
+
'cache-control': string;
|
|
1080
|
+
pragma: string;
|
|
1081
|
+
vary: string;
|
|
1082
|
+
};
|
|
1083
|
+
status: number;
|
|
1084
|
+
body?: string | Uint8Array;
|
|
1085
|
+
contentType?: string;
|
|
1086
|
+
stream?: PluginHttpRouteStream;
|
|
1087
|
+
cause?: unknown;
|
|
1088
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
1089
|
+
}>;
|
|
1090
|
+
workload?: ApiWorkload;
|
|
1091
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
1092
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
1093
|
+
answersOtherMethods?: boolean | undefined;
|
|
1094
|
+
path: string;
|
|
1095
|
+
match?: "prefix" | "exact";
|
|
1096
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
1097
|
+
maxBodyBytes?: number;
|
|
1098
|
+
originGuard?: "exempt";
|
|
1099
|
+
cors?: RestCors;
|
|
1100
|
+
credentials?: "bearer";
|
|
1101
|
+
}[];
|
|
1102
|
+
};
|
|
1103
|
+
|
|
1104
|
+
/** Private read-only transport. Base64 encodes at most 64KiB per chunk; no
|
|
1105
|
+
* request can select a filesystem root or publisher authority. */
|
|
1106
|
+
export declare const cmsSnapshotRoleTransferRest: (service: ReturnType<typeof createSnapshotRoleTransfer>) => {
|
|
1107
|
+
routes: {
|
|
1108
|
+
guards: RestGuard[];
|
|
1109
|
+
maxBodyBytes: number;
|
|
1110
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
1111
|
+
method: RestMethod;
|
|
1112
|
+
path: string;
|
|
1113
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
1114
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
1115
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
1116
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
1117
|
+
summary?: string;
|
|
1118
|
+
description?: string;
|
|
1119
|
+
example?: RestRouteExample;
|
|
1120
|
+
operationId?: string;
|
|
1121
|
+
tags?: ReadonlyArray<string>;
|
|
1122
|
+
projection?: RestRouteProjection;
|
|
1123
|
+
deprecated?: string;
|
|
1124
|
+
sunset?: string;
|
|
1125
|
+
version?: `v${number}`;
|
|
1126
|
+
cors?: RestCors;
|
|
1127
|
+
credentials?: "bearer";
|
|
1128
|
+
rateLimit?: RestRateLimit;
|
|
1129
|
+
streaming?: boolean;
|
|
1130
|
+
etag?: boolean;
|
|
1131
|
+
cache?: RestCache;
|
|
1132
|
+
}[];
|
|
1133
|
+
httpRoutes: {
|
|
1134
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
1135
|
+
headers: {
|
|
1136
|
+
'www-authenticate'?: string;
|
|
1137
|
+
'cache-control': string;
|
|
1138
|
+
pragma: string;
|
|
1139
|
+
vary: string;
|
|
1140
|
+
};
|
|
1141
|
+
status: number;
|
|
1142
|
+
body?: string | Uint8Array;
|
|
1143
|
+
contentType?: string;
|
|
1144
|
+
stream?: PluginHttpRouteStream;
|
|
1145
|
+
cause?: unknown;
|
|
1146
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
1147
|
+
}>;
|
|
1148
|
+
workload?: ApiWorkload;
|
|
1149
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
1150
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
1151
|
+
answersOtherMethods?: boolean | undefined;
|
|
1152
|
+
path: string;
|
|
1153
|
+
match?: "prefix" | "exact";
|
|
1154
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
1155
|
+
maxBodyBytes?: number;
|
|
1156
|
+
originGuard?: "exempt";
|
|
1157
|
+
cors?: RestCors;
|
|
1158
|
+
credentials?: "bearer";
|
|
1159
|
+
}[];
|
|
1160
|
+
};
|
|
1161
|
+
|
|
1162
|
+
export declare interface CmsStaticPathProgress {
|
|
1163
|
+
readonly id: string;
|
|
1164
|
+
readonly revision: number;
|
|
1165
|
+
readonly phase: StaticPathProgress['phase'];
|
|
1166
|
+
readonly enumerated: number;
|
|
1167
|
+
readonly set: SignedStaticPathSet | null;
|
|
1168
|
+
}
|
|
1169
|
+
|
|
1170
|
+
export declare interface CmsStaticPathRequest {
|
|
1171
|
+
readonly snapshot: CmsBuildSnapshotPin;
|
|
1172
|
+
readonly token: string;
|
|
1173
|
+
readonly consumerId: string;
|
|
1174
|
+
readonly buildId: string;
|
|
1175
|
+
readonly host: string;
|
|
1176
|
+
/** Omitted selects every enabled captured locale. Explicit selection is pinned. */
|
|
1177
|
+
readonly localeIds?: ReadonlyArray<string>;
|
|
1178
|
+
/** Omitted selects both owners; CMS-only excludes runtime/editor code. */
|
|
1179
|
+
readonly owners?: ReadonlyArray<StaticPathOwner>;
|
|
1180
|
+
}
|
|
1181
|
+
|
|
1182
|
+
/** Dedicated private coordinator routes; mount httpRoutes as plugin HTTP routes
|
|
1183
|
+
* and pass routes to OpenAPI. No public serving, ambient auth or token cache. */
|
|
1184
|
+
export declare const cmsStaticPathSetRest: (service: CmsStaticPathSets) => {
|
|
1185
|
+
routes: {
|
|
1186
|
+
guards: RestGuard[];
|
|
1187
|
+
maxBodyBytes: number;
|
|
1188
|
+
publicApiDescriptor?: PublicApiDescriptor;
|
|
1189
|
+
method: RestMethod;
|
|
1190
|
+
path: string;
|
|
1191
|
+
input?: Schema.Codec<Record<string, unknown>, any, never, never>;
|
|
1192
|
+
output: Schema.Codec<unknown, any, never, never>;
|
|
1193
|
+
handler: (input: Record<string, unknown>, ctx: RestRouteContext) => unknown;
|
|
1194
|
+
mapFailure?: (error: unknown, request: Pick< PluginHttpRouteRequest, "method" | "path" | "query">) => unknown;
|
|
1195
|
+
summary?: string;
|
|
1196
|
+
description?: string;
|
|
1197
|
+
example?: RestRouteExample;
|
|
1198
|
+
operationId?: string;
|
|
1199
|
+
tags?: ReadonlyArray<string>;
|
|
1200
|
+
projection?: RestRouteProjection;
|
|
1201
|
+
deprecated?: string;
|
|
1202
|
+
sunset?: string;
|
|
1203
|
+
version?: `v${number}`;
|
|
1204
|
+
cors?: RestCors;
|
|
1205
|
+
credentials?: "bearer";
|
|
1206
|
+
rateLimit?: RestRateLimit;
|
|
1207
|
+
streaming?: boolean;
|
|
1208
|
+
etag?: boolean;
|
|
1209
|
+
cache?: RestCache;
|
|
1210
|
+
}[];
|
|
1211
|
+
httpRoutes: {
|
|
1212
|
+
handle: (req: PluginHttpRouteRequest) => Promise<{
|
|
1213
|
+
headers: {
|
|
1214
|
+
'www-authenticate'?: string;
|
|
1215
|
+
'cache-control': string;
|
|
1216
|
+
pragma: string;
|
|
1217
|
+
vary: string;
|
|
1218
|
+
};
|
|
1219
|
+
status: number;
|
|
1220
|
+
body?: string | Uint8Array;
|
|
1221
|
+
contentType?: string;
|
|
1222
|
+
stream?: PluginHttpRouteStream;
|
|
1223
|
+
cause?: unknown;
|
|
1224
|
+
byteStream?: PluginHttpRouteByteStream;
|
|
1225
|
+
}>;
|
|
1226
|
+
workload?: ApiWorkload;
|
|
1227
|
+
restContract?: RestRouteDescriptor<any, any>;
|
|
1228
|
+
method: "*" | "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "HEAD" | "OPTIONS";
|
|
1229
|
+
answersOtherMethods?: boolean | undefined;
|
|
1230
|
+
path: string;
|
|
1231
|
+
match?: "prefix" | "exact";
|
|
1232
|
+
handleStream?: (req: PluginHttpRouteStreamRequest) => Promise< PluginHttpRouteResult>;
|
|
1233
|
+
maxBodyBytes?: number;
|
|
1234
|
+
originGuard?: "exempt";
|
|
1235
|
+
cors?: RestCors;
|
|
1236
|
+
credentials?: "bearer";
|
|
1237
|
+
}[];
|
|
1238
|
+
};
|
|
1239
|
+
|
|
1240
|
+
export declare interface CmsStaticPathSets {
|
|
1241
|
+
readonly begin: (request: CmsStaticPathRequest) => Effect.Effect<CmsStaticPathProgress, StaticPathSetUnavailable | StaticPathSetConflict>;
|
|
1242
|
+
readonly advance: (request: CmsStaticPathRequest & {
|
|
1243
|
+
readonly id: string;
|
|
1244
|
+
readonly revision: number;
|
|
1245
|
+
}) => Effect.Effect<CmsStaticPathProgress, StaticPathSetUnavailable | StaticPathSetConflict>;
|
|
1246
|
+
readonly page: (request: CmsStaticPathRequest & {
|
|
1247
|
+
readonly id: string;
|
|
1248
|
+
readonly digest: string;
|
|
1249
|
+
readonly index: number;
|
|
1250
|
+
}) => Effect.Effect<{
|
|
1251
|
+
readonly set: SignedStaticPathSet;
|
|
1252
|
+
readonly index: number;
|
|
1253
|
+
readonly entries: ReadonlyArray<StaticPathEntry>;
|
|
1254
|
+
readonly next: number | null;
|
|
1255
|
+
}, StaticPathSetUnavailable | StaticPathSetConflict>;
|
|
1256
|
+
}
|
|
1257
|
+
|
|
1258
|
+
export declare interface CmsStaticPathSetsOptions {
|
|
1259
|
+
readonly store: DataStore;
|
|
1260
|
+
readonly scope: ChangeFeedScope;
|
|
1261
|
+
readonly execution: SnapshotAppExecution;
|
|
1262
|
+
readonly key: RenderReadKey;
|
|
1263
|
+
readonly verificationKeys?: ReadonlyArray<RenderReadKey>;
|
|
1264
|
+
readonly now?: () => number;
|
|
1265
|
+
}
|
|
1266
|
+
|
|
1267
|
+
/**
|
|
1268
|
+
* A component editors compose pages from (ADR-CMS-015): a stable `id`, a
|
|
1269
|
+
* display name and typed props. The frontend renders it; the CMS validates
|
|
1270
|
+
* and stores instances of it. `fingerprint` changes whenever the prop contract
|
|
1271
|
+
* does, so a stored instance can tell which definition it was written against.
|
|
1272
|
+
*/
|
|
1273
|
+
declare interface ComponentDefinition {
|
|
1274
|
+
readonly id: string;
|
|
1275
|
+
readonly displayName: string;
|
|
1276
|
+
readonly props: Readonly<Record<string, FieldSchema>>;
|
|
1277
|
+
readonly fingerprint: string;
|
|
1278
|
+
/** What it is for, in an editor's words — searched by the picker. */
|
|
1279
|
+
readonly description?: string;
|
|
1280
|
+
/** The editorial jobs it serves (`'announce an event'`, `'collect leads'`) — the picker groups and searches by them. */
|
|
1281
|
+
readonly jobs?: ReadonlyArray<string>;
|
|
1282
|
+
/** Named presets an editor starts from (`dark`, `compact`): props that differ from empty. */
|
|
1283
|
+
readonly variants?: Readonly<Record<string, Readonly<Record<string, unknown>>>>;
|
|
1284
|
+
/** Example props — previews, galleries and tests render them; checked against `props` when a content type uses the component. */
|
|
1285
|
+
readonly fixtures?: Readonly<Record<string, Readonly<Record<string, unknown>>>>;
|
|
1286
|
+
/** Upgrades of instances saved against an earlier definition: its fingerprint → the props it becomes now. */
|
|
1287
|
+
readonly migrations?: Readonly<Record<string, (props: Readonly<Record<string, unknown>>) => Readonly<Record<string, unknown>>>>;
|
|
1288
|
+
/** The consent purpose a reader must grant before this component's props reach them (`gateConsent`). */
|
|
1289
|
+
readonly consent?: string;
|
|
1290
|
+
}
|
|
1291
|
+
|
|
1292
|
+
/** A reader's choices: purpose id → the version they allowed. */
|
|
1293
|
+
declare type ConsentChoices = Readonly<Record<string, number>>;
|
|
1294
|
+
|
|
1295
|
+
/** Something a reader can allow or refuse. */
|
|
1296
|
+
declare interface ConsentPurpose {
|
|
1297
|
+
readonly id: string;
|
|
1298
|
+
/** Raise it when what the reader agrees to changes. */
|
|
1299
|
+
readonly version: number;
|
|
1300
|
+
readonly displayName: string;
|
|
1301
|
+
readonly description: string;
|
|
1302
|
+
/** The third parties it lets in (none for a first-party purpose). */
|
|
1303
|
+
readonly vendors?: ReadonlyArray<ConsentVendor>;
|
|
1304
|
+
}
|
|
1305
|
+
|
|
1306
|
+
/**
|
|
1307
|
+
* A third party a purpose lets in — kept apart from the purpose itself: who
|
|
1308
|
+
* it is, where its content comes from (the origins a page may then load), what
|
|
1309
|
+
* it stores on the reader's device, and what it does with the data.
|
|
1310
|
+
*/
|
|
1311
|
+
declare interface ConsentVendor {
|
|
1312
|
+
/** camelCase, unique within the purpose — what a reader-facing text is keyed by. */
|
|
1313
|
+
readonly id: string;
|
|
1314
|
+
readonly name: string;
|
|
1315
|
+
/** `https://host` origins, exactly — the browser loads frames from them once the purpose is granted. */
|
|
1316
|
+
readonly origins: ReadonlyArray<string>;
|
|
1317
|
+
readonly storage: string;
|
|
1318
|
+
readonly dataUse: string;
|
|
1319
|
+
}
|
|
1320
|
+
|
|
1321
|
+
declare interface ContentLocation {
|
|
1322
|
+
/** Stable mapping identity. Changing a slug/path must not change this ID. */
|
|
1323
|
+
readonly id: string;
|
|
1324
|
+
readonly segments: ReadonlyArray<ContentLocationSegment>;
|
|
1325
|
+
}
|
|
1326
|
+
|
|
1327
|
+
/** A decoded literal segment, one string field, or the complete content-tree path. */
|
|
1328
|
+
declare type ContentLocationSegment = string | {
|
|
1329
|
+
readonly field: string;
|
|
1330
|
+
} | {
|
|
1331
|
+
readonly tree: true;
|
|
1332
|
+
};
|
|
1333
|
+
|
|
1334
|
+
declare interface ContentProjectionDefinition {
|
|
1335
|
+
readonly version: 1;
|
|
1336
|
+
readonly fields: ContentProjectionFields;
|
|
1337
|
+
}
|
|
1338
|
+
|
|
1339
|
+
declare interface ContentProjectionFields {
|
|
1340
|
+
readonly [field: string]: ContentProjectionNode;
|
|
1341
|
+
}
|
|
1342
|
+
|
|
1343
|
+
declare type ContentProjectionNode = true | {
|
|
1344
|
+
readonly object: ContentProjectionFields;
|
|
1345
|
+
} | {
|
|
1346
|
+
readonly array: ContentProjectionNode;
|
|
1347
|
+
} | {
|
|
1348
|
+
readonly variant: {
|
|
1349
|
+
readonly field: string;
|
|
1350
|
+
readonly cases: Readonly<Record<string, ContentProjectionFields>>;
|
|
1351
|
+
};
|
|
1352
|
+
};
|
|
1353
|
+
|
|
1354
|
+
declare interface ContentSeoDefaults {
|
|
1355
|
+
readonly title?: string;
|
|
1356
|
+
readonly description?: string;
|
|
1357
|
+
readonly social?: {
|
|
1358
|
+
readonly title?: string;
|
|
1359
|
+
readonly description?: string;
|
|
1360
|
+
};
|
|
1361
|
+
readonly robots?: SeoRobotsPolicy;
|
|
1362
|
+
readonly sitemap?: boolean;
|
|
1363
|
+
}
|
|
1364
|
+
|
|
1365
|
+
declare interface ContentSeoDefinition {
|
|
1366
|
+
readonly version: 1;
|
|
1367
|
+
readonly title: SeoTextMapping;
|
|
1368
|
+
readonly description?: SeoTextMapping;
|
|
1369
|
+
readonly social?: {
|
|
1370
|
+
readonly title?: SeoTextMapping;
|
|
1371
|
+
readonly description?: SeoTextMapping;
|
|
1372
|
+
readonly image?: string;
|
|
1373
|
+
};
|
|
1374
|
+
/** Route addresses remain authoritative; no independent URL field mapping. */
|
|
1375
|
+
readonly canonical?: 'route' | 'omit';
|
|
1376
|
+
readonly robots?: SeoRobotsPolicy;
|
|
1377
|
+
readonly sitemap?: boolean;
|
|
1378
|
+
readonly structuredData?: {
|
|
1379
|
+
readonly type: 'WebPage' | 'Article' | 'BlogPosting';
|
|
1380
|
+
/** A field the rendered main content actually shows, not the SEO override. */
|
|
1381
|
+
readonly title: string;
|
|
1382
|
+
readonly description?: string;
|
|
1383
|
+
readonly datePublished?: string;
|
|
1384
|
+
};
|
|
1385
|
+
}
|
|
1386
|
+
|
|
1387
|
+
/** A registered content type. */
|
|
1388
|
+
declare interface ContentType {
|
|
1389
|
+
readonly name: string;
|
|
1390
|
+
readonly displayName: string;
|
|
1391
|
+
readonly pluralName: string;
|
|
1392
|
+
readonly fields: Readonly<Record<string, FieldSchema>>;
|
|
1393
|
+
/** Original-file field of a versioned asset document. */
|
|
1394
|
+
readonly asset?: AssetConfig;
|
|
1395
|
+
readonly list?: ListConfig;
|
|
1396
|
+
readonly idPrefix?: string;
|
|
1397
|
+
/** Declared ISR revalidations fired by `revalidateContent` — see
|
|
1398
|
+
* `ContentTypeSpec.revalidate`. */
|
|
1399
|
+
readonly revalidate?: ContentTypeSpec['revalidate'];
|
|
1400
|
+
/** How the documents form a tree — see `ContentTypeSpec.tree`. */
|
|
1401
|
+
readonly tree?: TreeConfig;
|
|
1402
|
+
/** The field a document outside a tree is addressed by — see `ContentTypeSpec.address`. */
|
|
1403
|
+
readonly address?: string;
|
|
1404
|
+
/** Serializable delivery paths with stable mapping IDs; no publish reservation implied. */
|
|
1405
|
+
readonly locations?: ReadonlyArray<ContentLocation>;
|
|
1406
|
+
/** Required/invalid mapped values block publication; length recommendations do not. */
|
|
1407
|
+
readonly seo?: ContentSeoDefinition;
|
|
1408
|
+
/** Explicit delivery definitions supplying locale-specific SEO defaults. Requires `seo`. */
|
|
1409
|
+
readonly seoSites?: ReadonlyArray<SiteDeliveryDefinition>;
|
|
1410
|
+
/** Whether publishing needs an approved revision — see `ContentTypeSpec.review`. */
|
|
1411
|
+
readonly review?: {
|
|
1412
|
+
readonly required: boolean | 'workspace';
|
|
1413
|
+
readonly workflow?: ReviewWorkflow;
|
|
1414
|
+
};
|
|
1415
|
+
/** When documents may be used — see `ContentTypeSpec.availability`. */
|
|
1416
|
+
readonly availability?: AvailabilityConfig;
|
|
1417
|
+
/** The review cycle — see `ContentTypeSpec.lifecycle`. */
|
|
1418
|
+
readonly lifecycle?: LifecycleConfig;
|
|
1419
|
+
/** Templates and their rules — see `ContentTypeSpec.templates`. */
|
|
1420
|
+
readonly templates?: TemplatesConfig;
|
|
1421
|
+
/** Whether publishes land in the change feed — see `ContentTypeSpec.changeFeed`. */
|
|
1422
|
+
readonly changeFeed?: boolean;
|
|
1423
|
+
/** What makes a document findable — see `ContentTypeSpec.search`. */
|
|
1424
|
+
readonly search?: SearchConfig;
|
|
1425
|
+
/** What its documents are checked for — see `ContentTypeSpec.quality`. */
|
|
1426
|
+
readonly quality?: ReadonlyArray<QualityRule>;
|
|
1427
|
+
/** The vocabulary of a list field — see `ContentTypeSpec.taxonomy`. */
|
|
1428
|
+
readonly taxonomy?: TaxonomyConfig;
|
|
1429
|
+
/** Field names whose value is computed-on-save (derivedFrom). */
|
|
1430
|
+
readonly derivedFields: ReadonlyArray<string>;
|
|
1431
|
+
/** Field names marked unique-per-tenant (composite `(tenantId, field)` UNIQUE). */
|
|
1432
|
+
readonly uniqueFields: ReadonlyArray<string>;
|
|
1433
|
+
}
|
|
1434
|
+
|
|
1435
|
+
/** The user-authored spec passed to `defineContentType`. */
|
|
1436
|
+
declare interface ContentTypeSpec {
|
|
1437
|
+
readonly name: string;
|
|
1438
|
+
readonly displayName: string;
|
|
1439
|
+
readonly pluralName: string;
|
|
1440
|
+
readonly fields: Readonly<Record<string, FieldSchema | PipeableField>>;
|
|
1441
|
+
/** Explicit asset identity; the original is a required Media field. */
|
|
1442
|
+
readonly asset?: AssetConfig;
|
|
1443
|
+
readonly list?: ListConfig;
|
|
1444
|
+
/** Override the TypeID prefix for awkward plurals / long names. */
|
|
1445
|
+
readonly idPrefix?: string;
|
|
1446
|
+
/**
|
|
1447
|
+
* Arrange this type's documents in a tree (pages under pages): `parent` is
|
|
1448
|
+
* an optional `Schema.Reference` to this same type, `order` an optional
|
|
1449
|
+
* number field ordering siblings, `segment` the string field that forms the
|
|
1450
|
+
* path (the slug). Read it with `cms.tree` / `cms.route`.
|
|
1451
|
+
*/
|
|
1452
|
+
readonly tree?: TreeConfig;
|
|
1453
|
+
/**
|
|
1454
|
+
* For a type outside a tree whose documents have an address of their own
|
|
1455
|
+
* (a blog post's slug): the string field that is it. Every publish records
|
|
1456
|
+
* it, and a changed address leaves a redirect to the document — as moving a
|
|
1457
|
+
* page in a tree does. Read it with `redirectTarget(store, type, path, scope)`.
|
|
1458
|
+
*/
|
|
1459
|
+
readonly address?: string;
|
|
1460
|
+
/** Serializable delivery paths with stable mapping IDs; no publish reservation implied. */
|
|
1461
|
+
readonly locations?: ReadonlyArray<ContentLocation>;
|
|
1462
|
+
/** Required/invalid mapped values block publication; length recommendations do not. */
|
|
1463
|
+
readonly seo?: ContentSeoDefinition;
|
|
1464
|
+
/** Explicit delivery definitions supplying locale-specific SEO defaults. Requires `seo`. */
|
|
1465
|
+
readonly seoSites?: ReadonlyArray<SiteDeliveryDefinition>;
|
|
1466
|
+
/**
|
|
1467
|
+
* `required: true` publishes only revisions another editor approved
|
|
1468
|
+
* (`approveReview`) — for every path that publishes: single, release,
|
|
1469
|
+
* rollback, schedule. Register `cmsReviewsTable` when set. `'workspace'`:
|
|
1470
|
+
* each workspace decides (team.ts `setReviewRequired`, or a blueprint's
|
|
1471
|
+
* `team.reviewRequired`) — register `cmsTeamTable` too. With `workflow`
|
|
1472
|
+
* (`defineReviewWorkflow`), the approval is a workflow instance that
|
|
1473
|
+
* approved the exact revision — every applicable step decided — instead of
|
|
1474
|
+
* one approval; register `cmsWorkflowInstancesTable` and
|
|
1475
|
+
* `cmsWorkflowDecisionsTable`.
|
|
1476
|
+
*/
|
|
1477
|
+
readonly review?: {
|
|
1478
|
+
readonly required: boolean | 'workspace';
|
|
1479
|
+
readonly workflow?: ReviewWorkflow;
|
|
1480
|
+
};
|
|
1481
|
+
/**
|
|
1482
|
+
* When this type's documents may be used (`until`: a date/datetime field,
|
|
1483
|
+
* `blocked`: a boolean field). Publishing one records it; publishing
|
|
1484
|
+
* anything referencing a blocked or expired one is refused
|
|
1485
|
+
* (`ReferenceUnavailable`), and readers can leave it out
|
|
1486
|
+
* (`unavailableAmong`). Register `cmsAvailabilityTable` when set.
|
|
1487
|
+
*/
|
|
1488
|
+
readonly availability?: AvailabilityConfig;
|
|
1489
|
+
/**
|
|
1490
|
+
* How often a published document is checked again: its first publish sets
|
|
1491
|
+
* a review date `reviewEveryDays` ahead, `recertify` moves it on. Register
|
|
1492
|
+
* `cmsStewardshipTable` (it also holds each document's owner).
|
|
1493
|
+
*/
|
|
1494
|
+
readonly lifecycle?: LifecycleConfig;
|
|
1495
|
+
/**
|
|
1496
|
+
* Templates a new document can start from, and the rules a document built
|
|
1497
|
+
* from one keeps on every save (required components, the first one, at
|
|
1498
|
+
* most N of one). `field` stores the template id.
|
|
1499
|
+
*/
|
|
1500
|
+
readonly templates?: TemplatesConfig;
|
|
1501
|
+
/**
|
|
1502
|
+
* Append every publish and take-down of this type to the change feed
|
|
1503
|
+
* (`cms_changes`, read with `readChanges`), in the same transaction. Register
|
|
1504
|
+
* `cmsChangesTable` and `cmsChangeHeadsTable` for every publication writer;
|
|
1505
|
+
* this flag controls event emission, not publication coordination.
|
|
1506
|
+
*/
|
|
1507
|
+
readonly changeFeed?: boolean;
|
|
1508
|
+
/**
|
|
1509
|
+
* Make this type findable (`searchContent`): every save and publish writes
|
|
1510
|
+
* the variant's text to `cms_search` in the same transaction — `title`
|
|
1511
|
+
* ranked first, all other text (strings, rich text, component props) as the
|
|
1512
|
+
* body. Register `cmsSearchTable` when set.
|
|
1513
|
+
*/
|
|
1514
|
+
readonly search?: SearchConfig;
|
|
1515
|
+
/**
|
|
1516
|
+
* Quality rules (quality.ts): each names the causing field, the words an
|
|
1517
|
+
* editor reads, and whether publishing waits for it (`blocking`, default
|
|
1518
|
+
* true). A blocking finding is repaired at its field or excepted — one rule,
|
|
1519
|
+
* one variant, a reason, an end date, approved by someone else
|
|
1520
|
+
* (`requestQualityException` / `decideQualityException`). Register
|
|
1521
|
+
* `cmsQualityExceptionsTable` when set.
|
|
1522
|
+
*/
|
|
1523
|
+
readonly quality?: ReadonlyArray<QualityRule>;
|
|
1524
|
+
/**
|
|
1525
|
+
* A controlled vocabulary for one `Schema.Array(Schema.String)` field
|
|
1526
|
+
* (taxonomy.ts): every save folds case and spacing, maps synonyms to their
|
|
1527
|
+
* term and drops repeats; a term outside the vocabulary fails the save
|
|
1528
|
+
* (`unknown: 'keep'` keeps it).
|
|
1529
|
+
*/
|
|
1530
|
+
readonly taxonomy?: TaxonomyConfig;
|
|
1531
|
+
/**
|
|
1532
|
+
* ISR routes to drop when content of this type is published or
|
|
1533
|
+
* unpublished. `revalidateContent(type)` calls `revalidatePath` /
|
|
1534
|
+
* `revalidateTag` (from `@voltro/runtime`) for each entry, reaching every
|
|
1535
|
+
* `voltro start` replica — `publishDue` after its commits, a mutation from
|
|
1536
|
+
* a post-commit subscriber on `<type>_published` (the write ops run inside
|
|
1537
|
+
* the caller's transaction, so they cannot know when it commits).
|
|
1538
|
+
*
|
|
1539
|
+
* You DON'T need this on postgres for the plain publish case: a route
|
|
1540
|
+
* declaring `cacheInvalidatesOn: ['<type>_published']` is already dropped
|
|
1541
|
+
* by CDC when the published table changes. Declare routes here for the
|
|
1542
|
+
* cases CDC can't cover — non-postgres dialects, pattern purges of routes
|
|
1543
|
+
* whose loader reads this content indirectly, or tag fanout.
|
|
1544
|
+
*/
|
|
1545
|
+
readonly revalidate?: {
|
|
1546
|
+
/** Route patterns (`/blog/[slug]`) or concrete paths (`/pricing`). */
|
|
1547
|
+
readonly paths?: ReadonlyArray<string>;
|
|
1548
|
+
/** Tags matched against routes' `cacheInvalidatesOn` entries. */
|
|
1549
|
+
readonly tags?: ReadonlyArray<string>;
|
|
1550
|
+
};
|
|
1551
|
+
}
|
|
1552
|
+
|
|
1553
|
+
export declare const copyCmsPublicBuildIdentity: (value: unknown) => CmsPublicBuildIdentity;
|
|
1554
|
+
|
|
1555
|
+
/** Detached version pins; the actual application retains its notice/vendor text. */
|
|
1556
|
+
export declare const copySnapshotConsentPurposes: (value: unknown) => ReadonlyArray<SnapshotConsentPurpose>;
|
|
1557
|
+
|
|
1558
|
+
/** Detach a closed claim before asynchronous admission. This alone does not
|
|
1559
|
+
* admit any purpose; use admitSnapshotPresentation against the captured policy. */
|
|
1560
|
+
export declare const copySnapshotPresentationValue: (supplied: unknown) => SnapshotPresentation;
|
|
1561
|
+
|
|
1562
|
+
export declare const copyStaticPathManifest: (value: unknown) => StaticPathSetManifest;
|
|
1563
|
+
|
|
1564
|
+
/** Compose the existing capture/grant/read/render implementation for the exact
|
|
1565
|
+
* admitted application of each request. Selection and retained-code loading
|
|
1566
|
+
* happen outside SQL transactions, after native credential/grant admission;
|
|
1567
|
+
* the same admission is repeated afterwards. Underlying operations retain
|
|
1568
|
+
* their own original receipt, fresh rights and commit-time checks.
|
|
1569
|
+
*
|
|
1570
|
+
* This is not application admission or an upload API. Its server catalog must
|
|
1571
|
+
* already own verified immutable archives. No global current executor changes
|
|
1572
|
+
* when another application is added, and no authorization result is cached. */
|
|
1573
|
+
export declare const createCmsApplicationBuildSnapshots: (options: CmsApplicationBuildSnapshotsOptions) => CmsBuildSnapshots;
|
|
1574
|
+
|
|
1575
|
+
/** The original deployment association is immutable. Physical receive/open
|
|
1576
|
+
* runs outside SQL; native key fencing and the final lifetime check protect
|
|
1577
|
+
* the catalog commit. Even an exact retry verifies current source custody.
|
|
1578
|
+
* Neither a delivery-read key nor possession of an archive ID admits code. */
|
|
1579
|
+
export declare const createCmsBuildApplicationCatalog: (options: CmsBuildApplicationCatalogOptions) => CmsBuildApplicationCatalog;
|
|
1580
|
+
|
|
1581
|
+
/** A fixed tenant/site/environment service. Capture retries keep one durable
|
|
1582
|
+
* attempt and the original expiry; possession of its id never grants reads.
|
|
1583
|
+
* This creates private snapshots/output, not an activated website. */
|
|
1584
|
+
export declare const createCmsBuildSnapshots: (options: CmsBuildSnapshotsOptions) => CmsBuildSnapshots;
|
|
1585
|
+
|
|
1586
|
+
/** No application execution or live route enumeration occurs while preparing
|
|
1587
|
+
* metadata. The definitions are the actual retained, natively verified inputs.
|
|
1588
|
+
* Current graph/rights admission runs separately in the atomic deploy commit. */
|
|
1589
|
+
export declare const createCmsNativeOutputDeployments: (supplied: CmsNativeOutputDeploymentsOptions) => CmsNativeOutputDeployments;
|
|
1590
|
+
|
|
1591
|
+
/** Fixed tenant/site/environment and an explicit organization API-key scope.
|
|
1592
|
+
* No application execution, provider allocation or signer material is accepted
|
|
1593
|
+
* over the transport. All writes use the existing deployment/activation kernel.
|
|
1594
|
+
* Retrying an exactly committed current marker acknowledges that same result;
|
|
1595
|
+
* it never renews the expired probe or repeats a generation change. */
|
|
1596
|
+
export declare const createCmsOutputDeployments: (supplied: CmsOutputDeploymentsOptions) => CmsOutputDeployments;
|
|
1597
|
+
|
|
1598
|
+
export declare const createCmsPublicBuilds: (options: CmsPublicBuildsOptions) => CmsPublicBuilds;
|
|
1599
|
+
|
|
1600
|
+
export declare const createCmsPublicOutputs: (supplied: CmsPublicOutputsOptions) => CmsPublicOutputs;
|
|
1601
|
+
|
|
1602
|
+
/** One host per set; a site's activation combines the sets for all captured
|
|
1603
|
+
* hosts. A set cannot be selected by another host, locale filter or build. */
|
|
1604
|
+
export declare const createCmsStaticPathSets: (options: CmsStaticPathSetsOptions) => CmsStaticPathSets;
|
|
1605
|
+
|
|
1606
|
+
export declare const createOutputActivationSet: (value: unknown) => OutputActivationSet;
|
|
1607
|
+
|
|
1608
|
+
/** A private artifact ID is no activation or serving authority. All original
|
|
1609
|
+
* signed paths, complete document/class receipts and current media rights are
|
|
1610
|
+
* independently verified before and after physical composition and EOF reads.
|
|
1611
|
+
*/
|
|
1612
|
+
export declare const createSnapshotAssetAssembly: (options: {
|
|
1613
|
+
readonly store: DataStore;
|
|
1614
|
+
readonly scope: ChangeFeedScope;
|
|
1615
|
+
readonly provider: SnapshotOutputProvider;
|
|
1616
|
+
readonly use: SnapshotMediaUse;
|
|
1617
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
1618
|
+
readonly now?: () => number;
|
|
1619
|
+
}) => {
|
|
1620
|
+
render: (request: SnapshotAssetAssemblyRequest) => Promise<{
|
|
1621
|
+
artifactId: string;
|
|
1622
|
+
files: number;
|
|
1623
|
+
bytes: number;
|
|
1624
|
+
}>;
|
|
1625
|
+
};
|
|
1626
|
+
|
|
1627
|
+
/** Durable private coordination, without persisting any parent/grant token.
|
|
1628
|
+
* Immutable branches are allowed; only a complete, freshly admitted branch can
|
|
1629
|
+
* become a document artifact. No mutable head, lease or elapsed-time recovery.
|
|
1630
|
+
*/
|
|
1631
|
+
export declare const createSnapshotDocumentAssembly: (options: {
|
|
1632
|
+
readonly store: DataStore;
|
|
1633
|
+
readonly scope: ChangeFeedScope;
|
|
1634
|
+
readonly provider: SnapshotOutputProvider;
|
|
1635
|
+
readonly use: SnapshotMediaUse;
|
|
1636
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
1637
|
+
readonly now?: () => number;
|
|
1638
|
+
}) => {
|
|
1639
|
+
begin: (request: SnapshotDocumentAssemblyRequest) => Promise<SnapshotDocumentAssemblyProgress>;
|
|
1640
|
+
append: (request: SnapshotDocumentAssemblyRequest & SnapshotDocumentAssemblyCursor & {
|
|
1641
|
+
readonly documents: ReadonlyArray<SnapshotOutputDocumentPin>;
|
|
1642
|
+
}) => Promise<SnapshotDocumentAssemblyProgress>;
|
|
1643
|
+
seal: (request: SnapshotDocumentAssemblyRequest & SnapshotDocumentAssemblyCursor) => Promise<{
|
|
1644
|
+
artifactId: string;
|
|
1645
|
+
documents: number;
|
|
1646
|
+
bytes: number;
|
|
1647
|
+
}>;
|
|
1648
|
+
};
|
|
1649
|
+
|
|
1650
|
+
/** Re-admit the original grant, complete signed paths, renderer receipts and
|
|
1651
|
+
* current media rights on BOTH sides of every physical provider operation.
|
|
1652
|
+
* Caller metadata never chooses a provider root or an unbound artifact ID. */
|
|
1653
|
+
export declare const createSnapshotDocumentTransfer: (options: {
|
|
1654
|
+
readonly store: DataStore;
|
|
1655
|
+
readonly scope: ChangeFeedScope;
|
|
1656
|
+
readonly provider: SnapshotOutputProvider;
|
|
1657
|
+
readonly use: SnapshotMediaUse;
|
|
1658
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
1659
|
+
readonly now?: () => number;
|
|
1660
|
+
}) => {
|
|
1661
|
+
read: (request: SnapshotDocumentTransferRequest) => Promise<SnapshotOutputArtifact>;
|
|
1662
|
+
planFile: (request: Omit< CmsStaticPathRequest, "owners" | "localeIds"> & {
|
|
1663
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
1664
|
+
} & {
|
|
1665
|
+
readonly id: string;
|
|
1666
|
+
} & {
|
|
1667
|
+
readonly path: string;
|
|
1668
|
+
}) => Promise< SnapshotOutputFilePlan>;
|
|
1669
|
+
readChunk: (request: Omit< CmsStaticPathRequest, "owners" | "localeIds"> & {
|
|
1670
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
1671
|
+
} & {
|
|
1672
|
+
readonly id: string;
|
|
1673
|
+
} & {
|
|
1674
|
+
readonly file: SnapshotOutputFile;
|
|
1675
|
+
readonly chunk: SnapshotOutputFileChunk;
|
|
1676
|
+
}) => Promise<Uint8Array>;
|
|
1677
|
+
};
|
|
1678
|
+
|
|
1679
|
+
export declare const createSnapshotRoleTransfer: (options: {
|
|
1680
|
+
readonly store: DataStore;
|
|
1681
|
+
readonly scope: ChangeFeedScope;
|
|
1682
|
+
readonly provider: SnapshotOutputProvider;
|
|
1683
|
+
readonly use: SnapshotMediaUse;
|
|
1684
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
1685
|
+
readonly maxBytes: number;
|
|
1686
|
+
readonly declaration?: SnapshotRouteDeclaration;
|
|
1687
|
+
readonly now?: () => number;
|
|
1688
|
+
}) => {
|
|
1689
|
+
readBatch: (request: Omit< CmsStaticPathRequest, "owners" | "localeIds"> & {
|
|
1690
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
1691
|
+
} & {
|
|
1692
|
+
readonly role: SnapshotTransferRole;
|
|
1693
|
+
readonly id: string;
|
|
1694
|
+
readonly safety: {
|
|
1695
|
+
readonly artifactId: string;
|
|
1696
|
+
} | null;
|
|
1697
|
+
readonly targets: ReadonlyArray<SnapshotRedirectTargetDocuments>;
|
|
1698
|
+
} & {
|
|
1699
|
+
readonly files: ReadonlyArray< SnapshotOutputFile>;
|
|
1700
|
+
}) => Promise<Uint8Array>;
|
|
1701
|
+
read: (request: SnapshotRoleTransferRequest) => Promise<SnapshotOutputArtifact>;
|
|
1702
|
+
planFile: (request: Omit< CmsStaticPathRequest, "owners" | "localeIds"> & {
|
|
1703
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
1704
|
+
} & {
|
|
1705
|
+
readonly role: SnapshotTransferRole;
|
|
1706
|
+
readonly id: string;
|
|
1707
|
+
readonly safety: {
|
|
1708
|
+
readonly artifactId: string;
|
|
1709
|
+
} | null;
|
|
1710
|
+
readonly targets: ReadonlyArray<SnapshotRedirectTargetDocuments>;
|
|
1711
|
+
} & {
|
|
1712
|
+
readonly path: string;
|
|
1713
|
+
}) => Promise< SnapshotOutputFilePlan>;
|
|
1714
|
+
readChunk: (request: Omit< CmsStaticPathRequest, "owners" | "localeIds"> & {
|
|
1715
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
1716
|
+
} & {
|
|
1717
|
+
readonly role: SnapshotTransferRole;
|
|
1718
|
+
readonly id: string;
|
|
1719
|
+
readonly safety: {
|
|
1720
|
+
readonly artifactId: string;
|
|
1721
|
+
} | null;
|
|
1722
|
+
readonly targets: ReadonlyArray<SnapshotRedirectTargetDocuments>;
|
|
1723
|
+
} & {
|
|
1724
|
+
readonly file: SnapshotOutputFile;
|
|
1725
|
+
readonly chunk: SnapshotOutputFileChunk;
|
|
1726
|
+
}) => Promise<Uint8Array>;
|
|
1727
|
+
};
|
|
1728
|
+
|
|
1729
|
+
export declare const decodeCmsPublicBuildIdentity: (value: string) => CmsPublicBuildIdentity;
|
|
1730
|
+
|
|
1731
|
+
export declare const decodeSnapshotPresentation: (purposes: ReadonlyArray<SnapshotConsentPurpose>, selector: string) => SnapshotPresentation;
|
|
1732
|
+
|
|
1733
|
+
/** Validate actual callable bindings. Full schema compatibility is checked by
|
|
1734
|
+
* the shared descriptor encoder when the app describes its snapshot inputs. */
|
|
1735
|
+
export declare const defineFrontendBindings: (input: FrontendBindings) => FrontendBindings;
|
|
1736
|
+
|
|
1737
|
+
export declare const denyOutputTarget: (tx: DataStore, suppliedScope: OutputActivationScope, suppliedTarget: OutputSafetyTarget, reason: "security" | "rights" | "takedown") => Promise<number>;
|
|
1738
|
+
|
|
1739
|
+
/** A field marked computed-on-save from another field's value. */
|
|
1740
|
+
declare interface DerivedSpec {
|
|
1741
|
+
readonly source: string;
|
|
1742
|
+
readonly transform: (value: unknown, row: Record<string, unknown>) => unknown;
|
|
1743
|
+
}
|
|
1744
|
+
|
|
1745
|
+
/** The widget the editor renders for a field — drives ContentForm. */
|
|
1746
|
+
declare type EditorHint = 'text' | 'textarea' | 'number' | 'boolean' | 'date' | 'datetime' | 'select' | 'richText' | 'media' | 'reference' | 'array' | 'struct' | 'components';
|
|
1747
|
+
|
|
1748
|
+
/** Fixed ASCII framing needs no HTML attribute escaping and contains no site
|
|
1749
|
+
* credentials, actor, grant, personal consent or private input configuration. */
|
|
1750
|
+
export declare const encodeCmsPublicBuildIdentity: (value: CmsPublicBuildIdentity) => string;
|
|
1751
|
+
|
|
1752
|
+
/** A public class selector; this is not a credential or a reader identifier. */
|
|
1753
|
+
export declare const encodeSnapshotPresentation: (purposes: ReadonlyArray<SnapshotConsentPurpose>, presentation: SnapshotPresentation) => string;
|
|
1754
|
+
|
|
1755
|
+
/** Discriminator for how a field compiles to a column + serialises. */
|
|
1756
|
+
declare type FieldKind = 'string' | 'number' | 'boolean' | 'date' | 'datetime' | 'literal' | 'richText' | 'media' | 'reference' | 'array' | 'struct' | 'components';
|
|
1757
|
+
|
|
1758
|
+
/** A refinement applied through `.pipe(...)`. */
|
|
1759
|
+
declare type FieldRefinement = (field: FieldSchema) => FieldSchema;
|
|
1760
|
+
|
|
1761
|
+
/** A fully-resolved field descriptor stored on a content type. */
|
|
1762
|
+
declare interface FieldSchema {
|
|
1763
|
+
readonly kind: FieldKind;
|
|
1764
|
+
readonly editorHint: EditorHint;
|
|
1765
|
+
/** When true the field is nullable in the DB + optional in the editor. */
|
|
1766
|
+
readonly isOptional: boolean;
|
|
1767
|
+
/**
|
|
1768
|
+
* Set by `.requiredToPublish()`: a draft may leave it empty; publishing
|
|
1769
|
+
* needs it (`publishViolations`, checked by every publish). Implies
|
|
1770
|
+
* `isOptional` — the column is nullable.
|
|
1771
|
+
*/
|
|
1772
|
+
readonly publishRequired?: boolean;
|
|
1773
|
+
/** Max string length — drives textarea-vs-input + save-time validation. */
|
|
1774
|
+
readonly maxLength?: number;
|
|
1775
|
+
/** Source-form regex (string) for save-time validation. */
|
|
1776
|
+
readonly pattern?: string;
|
|
1777
|
+
/** Closed value set for `literal` fields → `<select>` + CHECK constraint. */
|
|
1778
|
+
readonly literals?: ReadonlyArray<string>;
|
|
1779
|
+
/** What an editor reads for each literal (a token's value, an action's purpose). */
|
|
1780
|
+
readonly literalLabels?: Readonly<Record<string, string>>;
|
|
1781
|
+
/** Set by `Schema.Token`: the design-token group the value names. */
|
|
1782
|
+
readonly token?: string;
|
|
1783
|
+
/** Set by `Schema.Action`: the value names an action the renderer binds. */
|
|
1784
|
+
readonly action?: true;
|
|
1785
|
+
/** A `number` field that takes fractions (a `real` column); without it a number is whole. */
|
|
1786
|
+
readonly fraction?: boolean;
|
|
1787
|
+
/**
|
|
1788
|
+
* When true, the field is unique PER TENANT — the derived tables carry a
|
|
1789
|
+
* composite `(tenantId, <field>)` DB UNIQUE constraint (see contentType.ts).
|
|
1790
|
+
* Only meaningful on a `string` field (typically a slug).
|
|
1791
|
+
*/
|
|
1792
|
+
readonly unique?: boolean;
|
|
1793
|
+
/** RichText options. */
|
|
1794
|
+
readonly richText?: RichTextOptions;
|
|
1795
|
+
/** Referenced content-type name for `reference` fields. */
|
|
1796
|
+
readonly referenceType?: string;
|
|
1797
|
+
/** Element field for `array` fields. */
|
|
1798
|
+
readonly element?: FieldSchema;
|
|
1799
|
+
/** Nested field map for `struct` fields. */
|
|
1800
|
+
readonly struct?: Readonly<Record<string, FieldSchema>>;
|
|
1801
|
+
/** The components a `components` field may hold, in the order editors see them. */
|
|
1802
|
+
readonly components?: ReadonlyArray<ComponentDefinition>;
|
|
1803
|
+
/** Computed-on-save derivation (set via `derivedFrom`). */
|
|
1804
|
+
readonly derived?: DerivedSpec;
|
|
1805
|
+
}
|
|
1806
|
+
|
|
1807
|
+
export declare type FrontendBindings = Readonly<Record<string, FrontendComponentBinding>>;
|
|
1808
|
+
|
|
1809
|
+
export declare interface FrontendComponentBinding {
|
|
1810
|
+
readonly schema: ComponentDefinition;
|
|
1811
|
+
readonly renderer: string;
|
|
1812
|
+
readonly contexts: ReadonlyArray<FrontendOutputContext>;
|
|
1813
|
+
readonly render: (props: Readonly<Record<string, unknown>>, context: FrontendOutputContext, resources: {
|
|
1814
|
+
readonly media: FrontendMediaReader;
|
|
1815
|
+
readonly source?: SnapshotComponentSource;
|
|
1816
|
+
}) => unknown;
|
|
1817
|
+
readonly empty: (input: FrontendStateInput) => unknown;
|
|
1818
|
+
readonly loading: (input: FrontendStateInput) => unknown;
|
|
1819
|
+
readonly error: (input: FrontendStateInput) => unknown;
|
|
1820
|
+
readonly restricted?: (input: FrontendStateInput & {
|
|
1821
|
+
readonly purpose: string;
|
|
1822
|
+
}) => unknown;
|
|
1823
|
+
}
|
|
1824
|
+
|
|
1825
|
+
export declare interface FrontendMedia extends FrontendMediaSelection, FrontendMediaFile {
|
|
1826
|
+
}
|
|
1827
|
+
|
|
1828
|
+
declare interface FrontendMediaFile {
|
|
1829
|
+
readonly url: string;
|
|
1830
|
+
readonly contentType: string;
|
|
1831
|
+
}
|
|
1832
|
+
|
|
1833
|
+
declare type FrontendMediaOutput = {
|
|
1834
|
+
readonly kind: 'original';
|
|
1835
|
+
} | {
|
|
1836
|
+
readonly kind: 'rendition';
|
|
1837
|
+
readonly slot: string;
|
|
1838
|
+
};
|
|
1839
|
+
|
|
1840
|
+
export declare type FrontendMediaReader = (path: ReadonlyArray<string | number>, output?: FrontendMediaOutput) => FrontendMediaFile | null;
|
|
1841
|
+
|
|
1842
|
+
export declare interface FrontendMediaSelection {
|
|
1843
|
+
readonly fieldPath: ReadonlyArray<string | number>;
|
|
1844
|
+
readonly output: FrontendMediaOutput;
|
|
1845
|
+
}
|
|
1846
|
+
|
|
1847
|
+
export declare interface FrontendOutputContext extends FrontendOutputSelection {
|
|
1848
|
+
readonly localeId: string;
|
|
1849
|
+
readonly contentLocale: string;
|
|
1850
|
+
readonly languageTag: string;
|
|
1851
|
+
readonly direction: 'ltr' | 'rtl';
|
|
1852
|
+
}
|
|
1853
|
+
|
|
1854
|
+
export declare interface FrontendOutputSelection {
|
|
1855
|
+
readonly channel: string;
|
|
1856
|
+
readonly theme: string;
|
|
1857
|
+
}
|
|
1858
|
+
|
|
1859
|
+
export declare interface FrontendStateInput {
|
|
1860
|
+
readonly componentId: string;
|
|
1861
|
+
readonly context: FrontendOutputContext;
|
|
1862
|
+
readonly source?: SnapshotComponentSource;
|
|
1863
|
+
}
|
|
1864
|
+
|
|
1865
|
+
/** How one inherited field may be set. */
|
|
1866
|
+
declare interface InheritRule {
|
|
1867
|
+
/** No page may set the field; saving one that does is refused (`locked`). */
|
|
1868
|
+
readonly locked?: boolean;
|
|
1869
|
+
/**
|
|
1870
|
+
* An optional Boolean field of the same type that MASKS this one: true on a
|
|
1871
|
+
* page means it shows nothing here, on purpose — not "unset" (that
|
|
1872
|
+
* inherits) and not an empty value. Pages below inherit the mask until one
|
|
1873
|
+
* sets its own value or mask. A locked field cannot be masked.
|
|
1874
|
+
*/
|
|
1875
|
+
readonly mask?: string;
|
|
1876
|
+
}
|
|
1877
|
+
|
|
1878
|
+
/** Explicit writers-stopped upgrade. Replay every issued activation from its
|
|
1879
|
+
* actual retained region and verify custody/current admission. Missing older
|
|
1880
|
+
* bytes refuse; today's routes cannot reconstruct unknown historical URLs.
|
|
1881
|
+
* The caller transaction makes the entire replay atomic. */
|
|
1882
|
+
export declare const initializeOutputRouteHistory: (tx: DataStore, suppliedScope: OutputActivationScope, options: {
|
|
1883
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
1884
|
+
readonly regionKeys: Readonly<Record<string, ReadonlyArray<RenderReadKey>>>;
|
|
1885
|
+
readonly admit: OutputActivationAdmission;
|
|
1886
|
+
readonly readRoutes: OutputActivationRouteInventory;
|
|
1887
|
+
}) => Promise<{
|
|
1888
|
+
readonly revision: number;
|
|
1889
|
+
readonly historyCount: number;
|
|
1890
|
+
}>;
|
|
1891
|
+
|
|
1892
|
+
/** How often a type's documents are checked again, declared on the type. */
|
|
1893
|
+
declare interface LifecycleConfig {
|
|
1894
|
+
/** Days from a publish or a recertification to the next review. */
|
|
1895
|
+
readonly reviewEveryDays: number;
|
|
1896
|
+
}
|
|
1897
|
+
|
|
1898
|
+
/**
|
|
1899
|
+
* List-view configuration for the consuming editor/template: which
|
|
1900
|
+
* columns its list page shows and the default sort. Validated by
|
|
1901
|
+
* `defineContentType` — every referenced name must be a declared field
|
|
1902
|
+
* or a lifecycle column, so a typo fails at definition time instead of
|
|
1903
|
+
* rendering an empty column.
|
|
1904
|
+
*/
|
|
1905
|
+
declare interface ListConfig {
|
|
1906
|
+
readonly columns: ReadonlyArray<string>;
|
|
1907
|
+
readonly defaultSort?: {
|
|
1908
|
+
readonly field: string;
|
|
1909
|
+
readonly dir: 'asc' | 'desc';
|
|
1910
|
+
};
|
|
1911
|
+
}
|
|
1912
|
+
|
|
1913
|
+
/** Whether a (nested) list is numbered. */
|
|
1914
|
+
declare type ListKind = 'ordered' | 'unordered';
|
|
1915
|
+
|
|
1916
|
+
/** One current candidate admission: deployment/publication, authenticated finite
|
|
1917
|
+
* membership, current namespace/intent/safety and media rights. It grants no
|
|
1918
|
+
* public response or private snapshot read and keeps the owning lock order. */
|
|
1919
|
+
export declare const makeOutputActivationAdmission: (supplied: OutputActivationAdmissionOptions) => OutputActivationAdmission;
|
|
1920
|
+
|
|
1921
|
+
/** Deployment/publication component, also usable during writers-stopped history
|
|
1922
|
+
* reconstruction. This alone is not a current route-graph admission. */
|
|
1923
|
+
export declare const makeOutputDeploymentAdmission: (verifyArtifacts: (tx: DataStore, set: OutputActivationSet) => Promise<void>) => OutputActivationAdmission;
|
|
1924
|
+
|
|
1925
|
+
export declare const makeOutputRegionReceipt: (probe: OutputActivationProbe, region: string, key: RenderReadKey, outputId: string) => OutputRegionReceipt;
|
|
1926
|
+
|
|
1927
|
+
/** Publication can advance while the previous complete output still serves.
|
|
1928
|
+
* Current deployment/policy conformance and target membership/rights cannot. */
|
|
1929
|
+
export declare const makeOutputServingAdmission: (verifyTarget: (tx: DataStore, set: OutputActivationSet, target: OutputSafetyTarget, receipt: OutputRegionReceipt) => Promise<void>) => OutputServingAdmission;
|
|
1930
|
+
|
|
1931
|
+
/** Mandatory trusted server adapter: rehash actual staged outputs and path-set
|
|
1932
|
+
* coverage, and lock/read current publication, deployment, contract and policy.
|
|
1933
|
+
* It must reject incompatible rolling deploys, including rollback targets.
|
|
1934
|
+
* Request fields or cached observations are never implementations of admission. */
|
|
1935
|
+
export declare type OutputActivationAdmission = (tx: DataStore, set: OutputActivationSet, mode: 'forward' | 'rollback') => Promise<OutputActivationObservation>;
|
|
1936
|
+
|
|
1937
|
+
export declare interface OutputActivationAdmissionOptions {
|
|
1938
|
+
/** Trusted immutable artifact reader. Rehash actual required regions and all
|
|
1939
|
+
* six roles; return one exact region's metadata plus original signed replies.
|
|
1940
|
+
* The CLI reader provides physical metadata without a CMS runtime dependency. */
|
|
1941
|
+
readonly verifyArtifacts: (tx: DataStore, set: OutputActivationSet) => Promise<OutputRouteGraphArtifacts>;
|
|
1942
|
+
readonly pathKeys: ReadonlyArray<RenderReadKey>;
|
|
1943
|
+
readonly use: (target: {
|
|
1944
|
+
readonly host: string;
|
|
1945
|
+
readonly path: string;
|
|
1946
|
+
}) => SnapshotMediaUse;
|
|
1947
|
+
readonly now?: () => number;
|
|
1948
|
+
}
|
|
1949
|
+
|
|
1950
|
+
export declare interface OutputActivationHostArtifacts {
|
|
1951
|
+
readonly host: string;
|
|
1952
|
+
readonly documents: string;
|
|
1953
|
+
readonly assets: string;
|
|
1954
|
+
readonly redirects: string;
|
|
1955
|
+
readonly sitemap: string;
|
|
1956
|
+
readonly robots: string;
|
|
1957
|
+
readonly deny: string;
|
|
1958
|
+
}
|
|
1959
|
+
|
|
1960
|
+
export declare interface OutputActivationManifest {
|
|
1961
|
+
readonly version: 2;
|
|
1962
|
+
readonly scope: OutputActivationScope;
|
|
1963
|
+
readonly snapshot: {
|
|
1964
|
+
readonly id: string;
|
|
1965
|
+
readonly digest: string;
|
|
1966
|
+
readonly releaseId: string;
|
|
1967
|
+
readonly publicationGeneration: string;
|
|
1968
|
+
};
|
|
1969
|
+
readonly app: {
|
|
1970
|
+
readonly deploymentId: string;
|
|
1971
|
+
readonly inputsId: string;
|
|
1972
|
+
readonly executionId: string;
|
|
1973
|
+
readonly contractVersion: number;
|
|
1974
|
+
readonly bindingsDigest: string;
|
|
1975
|
+
readonly schemaDigest: string;
|
|
1976
|
+
readonly cacheKeyDigest: string;
|
|
1977
|
+
};
|
|
1978
|
+
readonly renderPolicyDigest: string;
|
|
1979
|
+
readonly paths: ReadonlyArray<{
|
|
1980
|
+
readonly host: string;
|
|
1981
|
+
readonly setId: string;
|
|
1982
|
+
readonly count: number;
|
|
1983
|
+
}>;
|
|
1984
|
+
readonly artifacts: ReadonlyArray<OutputActivationHostArtifacts>;
|
|
1985
|
+
readonly cacheNamespace: string;
|
|
1986
|
+
readonly regions: {
|
|
1987
|
+
readonly required: ReadonlyArray<string>;
|
|
1988
|
+
readonly quorum: number;
|
|
1989
|
+
};
|
|
1990
|
+
}
|
|
1991
|
+
|
|
1992
|
+
export declare interface OutputActivationMarker {
|
|
1993
|
+
readonly id: string;
|
|
1994
|
+
readonly generation: number;
|
|
1995
|
+
readonly set: OutputActivationSet;
|
|
1996
|
+
readonly probe: OutputActivationProbe;
|
|
1997
|
+
readonly receipts: ReadonlyArray<OutputRegionReceipt>;
|
|
1998
|
+
readonly activatedAt: number;
|
|
1999
|
+
}
|
|
2000
|
+
|
|
2001
|
+
/** Fresh server observations, re-read under the caller's publication/app/policy
|
|
2002
|
+
* locks at probe and commit. Not accepted from an HTTP request or app worker. */
|
|
2003
|
+
export declare interface OutputActivationObservation {
|
|
2004
|
+
readonly publicationGeneration: string;
|
|
2005
|
+
readonly releaseId: string | null;
|
|
2006
|
+
readonly deploymentId: string;
|
|
2007
|
+
readonly renderPolicyDigest: string;
|
|
2008
|
+
readonly contractDigest: string;
|
|
2009
|
+
}
|
|
2010
|
+
|
|
2011
|
+
export declare interface OutputActivationProbe {
|
|
2012
|
+
readonly version: 1;
|
|
2013
|
+
readonly id: string;
|
|
2014
|
+
readonly targetId: string;
|
|
2015
|
+
readonly scope: OutputActivationScope;
|
|
2016
|
+
readonly expectedGeneration: number;
|
|
2017
|
+
readonly mode: 'forward' | 'rollback';
|
|
2018
|
+
readonly observation: OutputActivationObservation;
|
|
2019
|
+
readonly expiresAt: number;
|
|
2020
|
+
readonly keyId: string;
|
|
2021
|
+
readonly signature: string;
|
|
2022
|
+
}
|
|
2023
|
+
|
|
2024
|
+
/** Trusted server reader of the complete document inventory in this exact
|
|
2025
|
+
* receipted region. Admission separately verifies all physical bytes and signed
|
|
2026
|
+
* path sets. This port must never consume client-supplied URL lists. */
|
|
2027
|
+
export declare type OutputActivationRouteInventory = (set: OutputActivationSet, receipt: OutputRegionReceipt) => Promise<{
|
|
2028
|
+
readonly documentArtifacts: ReadonlyArray<{
|
|
2029
|
+
readonly host: string;
|
|
2030
|
+
readonly artifactId: string;
|
|
2031
|
+
}>;
|
|
2032
|
+
readonly routes: ReadonlyArray<{
|
|
2033
|
+
readonly url: string;
|
|
2034
|
+
readonly routeId: string;
|
|
2035
|
+
}>;
|
|
2036
|
+
}>;
|
|
2037
|
+
|
|
2038
|
+
export declare interface OutputActivationScope {
|
|
2039
|
+
readonly tenantId: string;
|
|
2040
|
+
readonly site: string;
|
|
2041
|
+
readonly environment: string;
|
|
2042
|
+
}
|
|
2043
|
+
|
|
2044
|
+
export declare interface OutputActivationSet {
|
|
2045
|
+
readonly id: string;
|
|
2046
|
+
readonly manifest: OutputActivationManifest;
|
|
2047
|
+
}
|
|
2048
|
+
|
|
2049
|
+
export declare class OutputActivationUnavailable extends OutputActivationUnavailable_base {
|
|
2050
|
+
}
|
|
2051
|
+
|
|
2052
|
+
declare const OutputActivationUnavailable_base: Schema.Class<OutputActivationUnavailable, Schema.TaggedStruct<"OutputActivationUnavailable", {
|
|
2053
|
+
readonly reason: Schema.Literals<readonly ["input", "integrity", "state", "changed", "generation", "regions", "denied", "expired"]>;
|
|
2054
|
+
}>, YieldableError>;
|
|
2055
|
+
|
|
2056
|
+
export declare interface OutputDeployment {
|
|
2057
|
+
readonly revision: number;
|
|
2058
|
+
readonly app: OutputActivationManifest['app'];
|
|
2059
|
+
readonly renderPolicyDigest: string;
|
|
2060
|
+
}
|
|
2061
|
+
|
|
2062
|
+
export declare interface OutputRegionReceipt {
|
|
2063
|
+
readonly version: 1;
|
|
2064
|
+
readonly probeId: string;
|
|
2065
|
+
readonly targetId: string;
|
|
2066
|
+
readonly generation: number;
|
|
2067
|
+
readonly region: string;
|
|
2068
|
+
readonly outputId: string;
|
|
2069
|
+
readonly keyId: string;
|
|
2070
|
+
readonly signature: string;
|
|
2071
|
+
}
|
|
2072
|
+
|
|
2073
|
+
/** Trusted provider data from exact verified private artifact roles. Signed
|
|
2074
|
+
* path evidence is the actual retained build reply, never a caller URL list.
|
|
2075
|
+
* Neither this data nor a signed path set grants serving authority. */
|
|
2076
|
+
export declare interface OutputRouteGraphArtifacts {
|
|
2077
|
+
readonly artifacts: ReadonlyArray<{
|
|
2078
|
+
readonly host: string;
|
|
2079
|
+
readonly documents: string;
|
|
2080
|
+
readonly redirects: string;
|
|
2081
|
+
readonly deny: string;
|
|
2082
|
+
}>;
|
|
2083
|
+
readonly documents: ReadonlyArray<{
|
|
2084
|
+
readonly url: string;
|
|
2085
|
+
readonly routeId: string;
|
|
2086
|
+
readonly media: ReadonlyArray<{
|
|
2087
|
+
readonly digest: string;
|
|
2088
|
+
readonly rights: unknown;
|
|
2089
|
+
}>;
|
|
2090
|
+
}>;
|
|
2091
|
+
readonly redirects: ReadonlyArray<unknown>;
|
|
2092
|
+
readonly safety: {
|
|
2093
|
+
readonly generation: number;
|
|
2094
|
+
readonly entries: ReadonlyArray<unknown>;
|
|
2095
|
+
};
|
|
2096
|
+
readonly producers: ReadonlyArray<{
|
|
2097
|
+
readonly consumerId: string;
|
|
2098
|
+
readonly buildId: string;
|
|
2099
|
+
readonly host: string;
|
|
2100
|
+
}>;
|
|
2101
|
+
readonly pathSets: ReadonlyArray<{
|
|
2102
|
+
readonly set: unknown;
|
|
2103
|
+
readonly pages: ReadonlyArray<unknown>;
|
|
2104
|
+
}>;
|
|
2105
|
+
}
|
|
2106
|
+
|
|
2107
|
+
export declare type OutputSafetyTarget = {
|
|
2108
|
+
readonly kind: 'url';
|
|
2109
|
+
readonly url: string;
|
|
2110
|
+
} | {
|
|
2111
|
+
readonly kind: 'asset';
|
|
2112
|
+
readonly digest: string;
|
|
2113
|
+
};
|
|
2114
|
+
|
|
2115
|
+
export declare type OutputServingAdmission = (tx: DataStore, set: OutputActivationSet, target: OutputSafetyTarget, receipt: OutputRegionReceipt) => Promise<void>;
|
|
2116
|
+
|
|
2117
|
+
/** One template a content type offers. */
|
|
2118
|
+
declare interface PageTemplate {
|
|
2119
|
+
/** Stable id, stored on the document. */
|
|
2120
|
+
readonly id: string;
|
|
2121
|
+
readonly displayName: string;
|
|
2122
|
+
/** Field values a new document starts with (e.g. a layout). */
|
|
2123
|
+
readonly values?: Readonly<Record<string, unknown>>;
|
|
2124
|
+
/** The components a new document starts with, in order. */
|
|
2125
|
+
readonly sections?: ReadonlyArray<{
|
|
2126
|
+
readonly component: ComponentDefinition;
|
|
2127
|
+
readonly props?: Readonly<Record<string, unknown>>;
|
|
2128
|
+
}>;
|
|
2129
|
+
/** Components the document must always hold at least once. */
|
|
2130
|
+
readonly required?: ReadonlyArray<ComponentDefinition>;
|
|
2131
|
+
/** The component that must come first. */
|
|
2132
|
+
readonly first?: ComponentDefinition;
|
|
2133
|
+
/** The most of one component the document may hold. */
|
|
2134
|
+
readonly max?: ReadonlyArray<{
|
|
2135
|
+
readonly component: ComponentDefinition;
|
|
2136
|
+
readonly count: number;
|
|
2137
|
+
}>;
|
|
2138
|
+
/** Other `Schema.Components` fields of the type (an aside), each with its own rules. */
|
|
2139
|
+
readonly regions?: Readonly<Record<string, RegionRule>>;
|
|
2140
|
+
/** The widths a component may take here: the values its `TemplatesConfig.width` prop may hold. */
|
|
2141
|
+
readonly widths?: ReadonlyArray<{
|
|
2142
|
+
readonly component: ComponentDefinition;
|
|
2143
|
+
readonly allowed: ReadonlyArray<string>;
|
|
2144
|
+
}>;
|
|
2145
|
+
/** How deep components may sit inside each other's slots; 1 = no nesting. */
|
|
2146
|
+
readonly maxDepth?: number;
|
|
2147
|
+
}
|
|
2148
|
+
|
|
2149
|
+
declare interface PipeableField extends FieldSchema {
|
|
2150
|
+
readonly isOptional: boolean;
|
|
2151
|
+
pipe(...refinements: ReadonlyArray<FieldRefinement>): PipeableField;
|
|
2152
|
+
/** Mark the field optional → nullable column + non-required editor input. */
|
|
2153
|
+
optional(): PipeableField;
|
|
2154
|
+
/**
|
|
2155
|
+
* Let a draft be saved without it, and refuse to publish until it is set —
|
|
2156
|
+
* an image uploaded in bulk before anyone wrote its alt text. The column is
|
|
2157
|
+
* nullable, like `optional()`.
|
|
2158
|
+
*/
|
|
2159
|
+
requiredToPublish(): PipeableField;
|
|
2160
|
+
}
|
|
2161
|
+
|
|
2162
|
+
export declare const probeOutputActivation: (tx: DataStore, supplied: OutputActivationSet, options: {
|
|
2163
|
+
readonly expectedGeneration: number;
|
|
2164
|
+
readonly mode: "forward" | "rollback";
|
|
2165
|
+
readonly key: RenderReadKey;
|
|
2166
|
+
readonly now: number;
|
|
2167
|
+
readonly ttlMs: number;
|
|
2168
|
+
readonly admit: OutputActivationAdmission;
|
|
2169
|
+
}) => Promise<OutputActivationProbe>;
|
|
2170
|
+
|
|
2171
|
+
/** When and where a quality rule is checked; `scope` is null where no place is known (every pack then applies). */
|
|
2172
|
+
declare interface QualityContext {
|
|
2173
|
+
readonly now: Date;
|
|
2174
|
+
readonly scope: CmsScope | null;
|
|
2175
|
+
}
|
|
2176
|
+
|
|
2177
|
+
/** One quality check of a type — see `ContentTypeSpec.quality`. */
|
|
2178
|
+
declare interface QualityRule {
|
|
2179
|
+
/** Stable id (letters, digits, `.`, `-`), unique in the type — exceptions name it. */
|
|
2180
|
+
readonly id: string;
|
|
2181
|
+
/** The field that causes the finding and where it is repaired. */
|
|
2182
|
+
readonly field: string;
|
|
2183
|
+
/** What is wrong, in the editor's words. */
|
|
2184
|
+
readonly message: string;
|
|
2185
|
+
/** Whether publishing waits for a repair or an approved exception. Default true. */
|
|
2186
|
+
readonly blocking?: boolean;
|
|
2187
|
+
/**
|
|
2188
|
+
* The policy pack it belongs to (`'EU claims'`, `'German market'`) — shown
|
|
2189
|
+
* beside the finding. With `sites` / `locales` a pack applies only there;
|
|
2190
|
+
* absent, everywhere.
|
|
2191
|
+
*/
|
|
2192
|
+
readonly pack?: string;
|
|
2193
|
+
readonly sites?: ReadonlyArray<string>;
|
|
2194
|
+
readonly locales?: ReadonlyArray<string>;
|
|
2195
|
+
/** True when the values have the finding. Pure; `at` says when and where (a claim's evidence may have run out). */
|
|
2196
|
+
readonly check: (values: Readonly<Record<string, unknown>>, at: QualityContext) => boolean;
|
|
2197
|
+
}
|
|
2198
|
+
|
|
2199
|
+
/** Serving adapters must invoke this for each response, including cached and
|
|
2200
|
+
* rollback responses. A marker alone never proves present rights/admission. */
|
|
2201
|
+
export declare const readActiveOutput: (tx: DataStore, suppliedScope: OutputActivationScope, suppliedTarget: OutputSafetyTarget, options: {
|
|
2202
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
2203
|
+
readonly regionKeys: Readonly<Record<string, ReadonlyArray<RenderReadKey>>>;
|
|
2204
|
+
readonly region: string;
|
|
2205
|
+
readonly admit: OutputServingAdmission;
|
|
2206
|
+
/** Shared only when the complete admission path is read-only and retains
|
|
2207
|
+
* shared barriers. History/control reads retain exclusive coordination. */
|
|
2208
|
+
readonly lock?: "update" | "share";
|
|
2209
|
+
}) => Promise<{
|
|
2210
|
+
readonly marker: OutputActivationMarker;
|
|
2211
|
+
readonly safetyGeneration: number;
|
|
2212
|
+
} | null>;
|
|
2213
|
+
|
|
2214
|
+
/** Private deployment metadata only. Reobserve a committed result after a lost
|
|
2215
|
+
* acknowledgement without renewing its expired probe or advancing generation.
|
|
2216
|
+
* This does not check current target membership, denials or serving rights;
|
|
2217
|
+
* public reads must still use readActiveOutput and its mandatory admission. */
|
|
2218
|
+
export declare const readOutputActivationMarker: (tx: DataStore, suppliedScope: OutputActivationScope, options: {
|
|
2219
|
+
readonly keys: ReadonlyArray<RenderReadKey>;
|
|
2220
|
+
readonly regionKeys: Readonly<Record<string, ReadonlyArray<RenderReadKey>>>;
|
|
2221
|
+
readonly lock?: "update" | "share";
|
|
2222
|
+
}) => Promise<OutputActivationMarker | null>;
|
|
2223
|
+
|
|
2224
|
+
/** Private original metadata only. Callers must still freshly authorize the
|
|
2225
|
+
* deployment and verify all physical roles/current graph before activation. */
|
|
2226
|
+
export declare const readOutputActivationTarget: (tx: DataStore, suppliedScope: OutputActivationScope, targetId: string) => Promise<RetainedOutputActivationTarget | null>;
|
|
2227
|
+
|
|
2228
|
+
/** Private current deployment metadata, without registering a deployment or
|
|
2229
|
+
* granting output/serving authority. Compose writes under the existing site
|
|
2230
|
+
* fence before this row lock, as bindOutputDeployment does. */
|
|
2231
|
+
export declare const readOutputDeployment: (tx: DataStore, suppliedScope: OutputActivationScope, options?: {
|
|
2232
|
+
readonly lock?: "update" | "share";
|
|
2233
|
+
}) => Promise<OutputDeployment | null>;
|
|
2234
|
+
|
|
2235
|
+
/** Trusted deployment metadata from the original retained job, not a new
|
|
2236
|
+
* snapshot/read grant. The caller must already own server deployment authority;
|
|
2237
|
+
* current graph, rights and output admission remain mandatory. Read every
|
|
2238
|
+
* original signed output page and its exact EOF without invoking live routes,
|
|
2239
|
+
* application code or a source enumerator. */
|
|
2240
|
+
export declare const readStaticPathSetEvidence: (tx: DataStore, suppliedScope: Pick<StaticPathSetContext, "tenantId" | "site" | "environment">, input: {
|
|
2241
|
+
readonly id: string;
|
|
2242
|
+
readonly digest: string;
|
|
2243
|
+
}, keys: ReadonlyArray<RenderReadKey>) => Promise<StaticPathSetEvidence>;
|
|
2244
|
+
|
|
2245
|
+
/** The rules of one region of a template. */
|
|
2246
|
+
declare interface RegionRule {
|
|
2247
|
+
/** Only these components may be placed here (all the field allows, when unset). */
|
|
2248
|
+
readonly allowed?: ReadonlyArray<ComponentDefinition>;
|
|
2249
|
+
readonly required?: ReadonlyArray<ComponentDefinition>;
|
|
2250
|
+
/** The most components the region may hold. */
|
|
2251
|
+
readonly maxItems?: number;
|
|
2252
|
+
}
|
|
2253
|
+
|
|
2254
|
+
/** An explicitly supplied server key. Never a default or stored with the grant. */
|
|
2255
|
+
export declare interface RenderReadKey {
|
|
2256
|
+
readonly id: string;
|
|
2257
|
+
readonly material: Uint8Array;
|
|
2258
|
+
}
|
|
2259
|
+
|
|
2260
|
+
export declare interface RetainedOutputActivationTarget {
|
|
2261
|
+
readonly set: OutputActivationSet;
|
|
2262
|
+
readonly pathSets: ReadonlyArray<{
|
|
2263
|
+
readonly host: string;
|
|
2264
|
+
readonly jobId: string;
|
|
2265
|
+
}>;
|
|
2266
|
+
readonly outputs: ReadonlyArray<{
|
|
2267
|
+
readonly region: string;
|
|
2268
|
+
readonly outputId: string;
|
|
2269
|
+
}>;
|
|
2270
|
+
}
|
|
2271
|
+
|
|
2272
|
+
/** Retain one exact original selection in a caller-owned deployment transaction.
|
|
2273
|
+
* Original signed path pages must exist. Roots, providers, keys and bearer
|
|
2274
|
+
* credentials never enter this record. Physical output IDs are coordinates;
|
|
2275
|
+
* this metadata alone neither attests bytes nor grants activation authority. */
|
|
2276
|
+
export declare const retainOutputActivationTarget: (tx: DataStore, suppliedScope: OutputActivationScope, supplied: RetainedOutputActivationTarget, keys: ReadonlyArray<RenderReadKey>) => Promise<RetainedOutputActivationTarget>;
|
|
2277
|
+
|
|
2278
|
+
declare interface ReviewWorkflow {
|
|
2279
|
+
readonly id: string;
|
|
2280
|
+
/** Raise it whenever the steps change: an instance keeps the version it started with. */
|
|
2281
|
+
readonly version: number;
|
|
2282
|
+
readonly steps: ReadonlyArray<WorkflowStep>;
|
|
2283
|
+
}
|
|
2284
|
+
|
|
2285
|
+
/** A top-level block. `id` is stable across edits, moves and translations. `style`
|
|
2286
|
+
* names a token of the profile's style group; `change` marks a block suggested
|
|
2287
|
+
* for insertion or deletion. */
|
|
2288
|
+
declare type RichBlock = {
|
|
2289
|
+
readonly id: string;
|
|
2290
|
+
readonly change?: RichChange;
|
|
2291
|
+
readonly type: 'paragraph';
|
|
2292
|
+
readonly content: ReadonlyArray<RichInline>;
|
|
2293
|
+
readonly style?: string;
|
|
2294
|
+
} | {
|
|
2295
|
+
readonly id: string;
|
|
2296
|
+
readonly change?: RichChange;
|
|
2297
|
+
readonly type: 'heading';
|
|
2298
|
+
readonly level: 2 | 3;
|
|
2299
|
+
readonly content: ReadonlyArray<RichInline>;
|
|
2300
|
+
readonly style?: string;
|
|
2301
|
+
} | {
|
|
2302
|
+
readonly id: string;
|
|
2303
|
+
readonly change?: RichChange;
|
|
2304
|
+
readonly type: 'list';
|
|
2305
|
+
readonly style?: string;
|
|
2306
|
+
readonly ordered: boolean;
|
|
2307
|
+
readonly items: ReadonlyArray<ReadonlyArray<RichInline>>;
|
|
2308
|
+
/** How deep each item sits (0 at the top, at most `MAX_LIST_LEVEL`), one per item; absent: all at the top.
|
|
2309
|
+
* An item is at most one level deeper than the one before it. */
|
|
2310
|
+
readonly levels?: ReadonlyArray<number>;
|
|
2311
|
+
/** The kind of the lists nested in it, by depth — index 0 for the lists one level in. Absent (or
|
|
2312
|
+
* shorter than the depth): numbered like the list itself. At most `MAX_LIST_LEVEL` entries. */
|
|
2313
|
+
readonly sublists?: ReadonlyArray<ListKind>;
|
|
2314
|
+
} | {
|
|
2315
|
+
readonly id: string;
|
|
2316
|
+
readonly change?: RichChange;
|
|
2317
|
+
readonly type: 'table';
|
|
2318
|
+
/** True when the first row holds the column headers. */
|
|
2319
|
+
readonly header: boolean;
|
|
2320
|
+
readonly rows: ReadonlyArray<ReadonlyArray<ReadonlyArray<RichInline>>>;
|
|
2321
|
+
}
|
|
2322
|
+
/** An image asset (by its documentId) with an optional caption. */
|
|
2323
|
+
| {
|
|
2324
|
+
readonly id: string;
|
|
2325
|
+
readonly change?: RichChange;
|
|
2326
|
+
readonly type: 'image';
|
|
2327
|
+
readonly asset: string;
|
|
2328
|
+
readonly caption?: string;
|
|
2329
|
+
}
|
|
2330
|
+
/** A file to download — an asset (by its documentId) from the media library — and the text its link shows. */
|
|
2331
|
+
| {
|
|
2332
|
+
readonly id: string;
|
|
2333
|
+
readonly change?: RichChange;
|
|
2334
|
+
readonly type: 'file';
|
|
2335
|
+
readonly asset: string;
|
|
2336
|
+
readonly label: string;
|
|
2337
|
+
}
|
|
2338
|
+
/** A component the profile allows, placed between blocks; `id` is its instance id. */
|
|
2339
|
+
| {
|
|
2340
|
+
readonly id: string;
|
|
2341
|
+
readonly change?: RichChange;
|
|
2342
|
+
readonly type: 'component';
|
|
2343
|
+
readonly componentId: string;
|
|
2344
|
+
readonly props: Readonly<Record<string, unknown>>;
|
|
2345
|
+
/** The definition's fingerprint when it was last saved. */
|
|
2346
|
+
readonly fingerprint?: string;
|
|
2347
|
+
};
|
|
2348
|
+
|
|
2349
|
+
/** A kind of block. */
|
|
2350
|
+
declare type RichBlockKind = RichBlock['type'];
|
|
2351
|
+
|
|
2352
|
+
/** A suggested change (track changes): text or a block someone proposes to insert
|
|
2353
|
+
* or delete, until it is accepted or rejected (trackChanges.ts). */
|
|
2354
|
+
declare interface RichChange {
|
|
2355
|
+
readonly id: string;
|
|
2356
|
+
readonly kind: 'insert' | 'delete';
|
|
2357
|
+
/** Who suggested it. */
|
|
2358
|
+
readonly by: string;
|
|
2359
|
+
/** When, as an ISO timestamp. */
|
|
2360
|
+
readonly at: string;
|
|
2361
|
+
}
|
|
2362
|
+
|
|
2363
|
+
/** How a contact is given: a published contact point (its documentId), or a one-off address or number. */
|
|
2364
|
+
declare type RichContact = {
|
|
2365
|
+
readonly target: string;
|
|
2366
|
+
} | {
|
|
2367
|
+
readonly channel: 'email' | 'phone';
|
|
2368
|
+
readonly value: string;
|
|
2369
|
+
};
|
|
2370
|
+
|
|
2371
|
+
/** A run of text inside a block. `change` marks it as suggested. */
|
|
2372
|
+
declare type RichInline =
|
|
2373
|
+
/** `style` names a token of the profile's style group (`lead`, `note`). */
|
|
2374
|
+
{
|
|
2375
|
+
readonly type: 'text';
|
|
2376
|
+
readonly text: string;
|
|
2377
|
+
readonly marks?: ReadonlyArray<RichMark>;
|
|
2378
|
+
readonly style?: string;
|
|
2379
|
+
readonly change?: RichChange;
|
|
2380
|
+
}
|
|
2381
|
+
/** A link to a document (by its documentId) — the site resolves its address. */
|
|
2382
|
+
| {
|
|
2383
|
+
readonly type: 'link';
|
|
2384
|
+
readonly target: string;
|
|
2385
|
+
readonly text: string;
|
|
2386
|
+
readonly change?: RichChange;
|
|
2387
|
+
}
|
|
2388
|
+
/** An e-mail address or a phone number — the site makes it a `mailto:` / `tel:` link. */
|
|
2389
|
+
| {
|
|
2390
|
+
readonly type: 'contact';
|
|
2391
|
+
readonly text: string;
|
|
2392
|
+
readonly contact: RichContact;
|
|
2393
|
+
readonly change?: RichChange;
|
|
2394
|
+
};
|
|
2395
|
+
|
|
2396
|
+
/** An inline mark. */
|
|
2397
|
+
declare type RichMark = 'bold' | 'italic' | 'underline';
|
|
2398
|
+
|
|
2399
|
+
/**
|
|
2400
|
+
* Which resources a rich-text field may hold: `images` names the content type
|
|
2401
|
+
* an image block references (an asset type), `files` the type a download
|
|
2402
|
+
* block references (an asset type), `links` the type a link references (a
|
|
2403
|
+
* page type). Unset → that node is not allowed.
|
|
2404
|
+
*/
|
|
2405
|
+
declare interface RichTextOptions {
|
|
2406
|
+
readonly images?: string;
|
|
2407
|
+
/** The asset type a download block references; unset → no downloads. */
|
|
2408
|
+
readonly files?: string;
|
|
2409
|
+
readonly links?: string;
|
|
2410
|
+
/** What this field allows beyond that; without one, every built-in block and mark, no styles, components or contacts. */
|
|
2411
|
+
readonly profile?: RichTextProfile;
|
|
2412
|
+
}
|
|
2413
|
+
|
|
2414
|
+
/** What a rich-text field allows (`defineRichTextProfile`). Versioned: a change bumps `version`. */
|
|
2415
|
+
declare interface RichTextProfile {
|
|
2416
|
+
readonly name: string;
|
|
2417
|
+
readonly version: number;
|
|
2418
|
+
/** `<name>@<version>` — what a saved document records. */
|
|
2419
|
+
readonly id: string;
|
|
2420
|
+
readonly blocks: ReadonlyArray<RichBlockKind>;
|
|
2421
|
+
readonly headings: ReadonlyArray<2 | 3>;
|
|
2422
|
+
readonly marks: ReadonlyArray<RichMark>;
|
|
2423
|
+
/** Named styles of paragraphs, headings, lists and runs of text: one design-token group, name → meaning. */
|
|
2424
|
+
readonly styles?: {
|
|
2425
|
+
readonly group: string;
|
|
2426
|
+
readonly tokens: Readonly<Record<string, string>>;
|
|
2427
|
+
};
|
|
2428
|
+
/** The components that may sit between the blocks. */
|
|
2429
|
+
readonly components: ReadonlyArray<ComponentDefinition>;
|
|
2430
|
+
/** The content type of the published contact points (e-mail, phone) a text may name. */
|
|
2431
|
+
readonly contactPoints?: string;
|
|
2432
|
+
/** Whether a text may hold a one-off e-mail address or phone number (checked on save). */
|
|
2433
|
+
readonly contactLiterals: boolean;
|
|
2434
|
+
}
|
|
2435
|
+
|
|
2436
|
+
/** What makes a type findable. */
|
|
2437
|
+
declare interface SearchConfig {
|
|
2438
|
+
/** The string field ranked first — usually the title. */
|
|
2439
|
+
readonly title: string;
|
|
2440
|
+
}
|
|
2441
|
+
|
|
2442
|
+
declare interface SeoRobotsPolicy {
|
|
2443
|
+
readonly index: boolean;
|
|
2444
|
+
readonly follow: boolean;
|
|
2445
|
+
}
|
|
2446
|
+
|
|
2447
|
+
declare interface SeoTextMapping {
|
|
2448
|
+
readonly fields: ReadonlyArray<string>;
|
|
2449
|
+
readonly required?: boolean;
|
|
2450
|
+
/** An editorial recommendation, never an invented search-engine limit. */
|
|
2451
|
+
readonly recommendedMaxLength?: number;
|
|
2452
|
+
}
|
|
2453
|
+
|
|
2454
|
+
export declare interface SignedStaticPathSet {
|
|
2455
|
+
readonly id: string;
|
|
2456
|
+
readonly manifest: StaticPathSetManifest;
|
|
2457
|
+
readonly keyId: string;
|
|
2458
|
+
readonly signature: string;
|
|
2459
|
+
}
|
|
2460
|
+
|
|
2461
|
+
declare interface SiteDeliveryDefinition {
|
|
2462
|
+
readonly id: string;
|
|
2463
|
+
readonly version: number;
|
|
2464
|
+
readonly environments: ReadonlyArray<string>;
|
|
2465
|
+
readonly defaultEnvironment: string;
|
|
2466
|
+
readonly locales: ReadonlyArray<SiteDeliveryLocale>;
|
|
2467
|
+
readonly defaultLocale: string;
|
|
2468
|
+
readonly sourceLocale: string;
|
|
2469
|
+
/** Named site-content bindings and their registered content type names. */
|
|
2470
|
+
readonly bindings: Readonly<Record<string, string>>;
|
|
2471
|
+
/** Editorial defaults keyed by stable locale identity, never request language guesses. */
|
|
2472
|
+
readonly seo?: Readonly<Record<string, ContentSeoDefaults>>;
|
|
2473
|
+
}
|
|
2474
|
+
|
|
2475
|
+
declare interface SiteDeliveryLocale {
|
|
2476
|
+
readonly id: string;
|
|
2477
|
+
/** An explicitly approved language tag; this compiler never canonicalizes it. */
|
|
2478
|
+
readonly tag: string;
|
|
2479
|
+
/** Existing published/draft row partition. Renaming a tag does not rewrite it. */
|
|
2480
|
+
readonly contentLocale: string;
|
|
2481
|
+
readonly direction: 'ltr' | 'rtl';
|
|
2482
|
+
readonly enabled: boolean;
|
|
2483
|
+
readonly prefix: string;
|
|
2484
|
+
/** Ordered fallback locale IDs, independent of translation source. */
|
|
2485
|
+
readonly fallback: ReadonlyArray<string>;
|
|
2486
|
+
}
|
|
2487
|
+
|
|
2488
|
+
declare const SNAPSHOT_PARTS: readonly ["release", "environment", "site", "domains", "locales", "routes", "schema", "components", "assets", "redirects", "seo", "policies", "projection", "app"];
|
|
2489
|
+
|
|
2490
|
+
/** Must come from the admitted build artifact/config, never a request claim. */
|
|
2491
|
+
export declare interface SnapshotAppCodePin {
|
|
2492
|
+
readonly commit: string;
|
|
2493
|
+
readonly artifactDigest: string;
|
|
2494
|
+
readonly configDigest: string;
|
|
2495
|
+
}
|
|
2496
|
+
|
|
2497
|
+
/** Trusted server provider. No compiler, filesystem paths or credentials are
|
|
2498
|
+
* part of this boundary; the CLI installs its retained Node JSON executor. */
|
|
2499
|
+
export declare interface SnapshotAppExecution {
|
|
2500
|
+
readonly run: (request: {
|
|
2501
|
+
readonly inputsId: string;
|
|
2502
|
+
readonly executionId: string;
|
|
2503
|
+
readonly exportName: 'describe' | 'definitions' | 'render' | '__voltro_routes' | '__voltro_staticPaths' | '__voltro_renderPage' | '__voltro_renderCmsPage';
|
|
2504
|
+
readonly inputJson: string;
|
|
2505
|
+
}) => Promise<{
|
|
2506
|
+
readonly value: unknown;
|
|
2507
|
+
readonly receipt: Readonly<Record<string, unknown>>;
|
|
2508
|
+
}>;
|
|
2509
|
+
}
|
|
2510
|
+
|
|
2511
|
+
export declare interface SnapshotApplicationDefinition {
|
|
2512
|
+
readonly types: ReadonlyArray<ContentType>;
|
|
2513
|
+
readonly site: SiteDeliveryDefinition;
|
|
2514
|
+
readonly access: Readonly<Record<string, SnapshotPublicAccess>>;
|
|
2515
|
+
readonly projection: SnapshotProjectionSelection;
|
|
2516
|
+
readonly renditions: ReadonlyArray<SnapshotRenditionRequirement>;
|
|
2517
|
+
readonly xDefault: boolean;
|
|
2518
|
+
readonly frontend: FrontendBindings;
|
|
2519
|
+
readonly output: FrontendOutputSelection;
|
|
2520
|
+
readonly routing: SnapshotRoutingDefinition | null;
|
|
2521
|
+
/** Version pins from the actual application's public consent declarations. */
|
|
2522
|
+
readonly consentPurposes?: ReadonlyArray<SnapshotConsentPurpose>;
|
|
2523
|
+
}
|
|
2524
|
+
|
|
2525
|
+
/** Frontend declaration producer: validate actual callable implementations in
|
|
2526
|
+
* the retained application, then emit their portable references. */
|
|
2527
|
+
export declare const snapshotApplicationPins: (definition: SnapshotApplicationDefinition, code: SnapshotAppCodePin) => {
|
|
2528
|
+
frontend: {
|
|
2529
|
+
version: 2;
|
|
2530
|
+
output: FrontendOutputSelection;
|
|
2531
|
+
components: {
|
|
2532
|
+
render: {
|
|
2533
|
+
kind: string;
|
|
2534
|
+
app: SnapshotAppCodePin;
|
|
2535
|
+
path: string[];
|
|
2536
|
+
};
|
|
2537
|
+
restricted: {
|
|
2538
|
+
kind: string;
|
|
2539
|
+
app: SnapshotAppCodePin;
|
|
2540
|
+
path: string[];
|
|
2541
|
+
} | null;
|
|
2542
|
+
empty: {
|
|
2543
|
+
kind: string;
|
|
2544
|
+
app: SnapshotAppCodePin;
|
|
2545
|
+
path: string[];
|
|
2546
|
+
};
|
|
2547
|
+
loading: {
|
|
2548
|
+
kind: string;
|
|
2549
|
+
app: SnapshotAppCodePin;
|
|
2550
|
+
path: string[];
|
|
2551
|
+
};
|
|
2552
|
+
error: {
|
|
2553
|
+
kind: string;
|
|
2554
|
+
app: SnapshotAppCodePin;
|
|
2555
|
+
path: string[];
|
|
2556
|
+
};
|
|
2557
|
+
id: string;
|
|
2558
|
+
digest: string;
|
|
2559
|
+
renderer: string;
|
|
2560
|
+
contexts: readonly FrontendOutputContext[];
|
|
2561
|
+
}[];
|
|
2562
|
+
};
|
|
2563
|
+
version: 2;
|
|
2564
|
+
app: SnapshotAppCodePin;
|
|
2565
|
+
parts: SnapshotPartPin[];
|
|
2566
|
+
site: SiteDeliveryDefinition;
|
|
2567
|
+
renditions: readonly SnapshotRenditionRequirement[];
|
|
2568
|
+
xDefault: boolean;
|
|
2569
|
+
routing: SnapshotRoutingDefinition | null;
|
|
2570
|
+
consentPurposes: readonly SnapshotConsentPurpose[];
|
|
2571
|
+
};
|
|
2572
|
+
|
|
2573
|
+
export declare type SnapshotAssetAssemblyRequest = Omit<CmsStaticPathRequest, 'localeIds' | 'owners'> & {
|
|
2574
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
2575
|
+
};
|
|
2576
|
+
|
|
2577
|
+
export declare interface SnapshotBindingRead {
|
|
2578
|
+
readonly snapshotId: string;
|
|
2579
|
+
readonly snapshotDigest: string;
|
|
2580
|
+
readonly binding: string;
|
|
2581
|
+
readonly contentType: string;
|
|
2582
|
+
readonly localeId: string;
|
|
2583
|
+
readonly requestedLocale: string;
|
|
2584
|
+
readonly sourceLocale: string;
|
|
2585
|
+
readonly fallback: boolean;
|
|
2586
|
+
readonly values: Readonly<Record<string, unknown>>;
|
|
2587
|
+
readonly presentation: SnapshotPresentation;
|
|
2588
|
+
}
|
|
2589
|
+
|
|
2590
|
+
/** API-side configuration may use the retained portable renderer declaration.
|
|
2591
|
+
* Explicit callbacks, when supplied, still have to match that declaration. */
|
|
2592
|
+
export declare interface SnapshotCaptureApplicationDefinition extends Omit<SnapshotApplicationDefinition, 'frontend'> {
|
|
2593
|
+
readonly frontend?: FrontendBindings;
|
|
2594
|
+
}
|
|
2595
|
+
|
|
2596
|
+
export declare interface SnapshotComponentSource {
|
|
2597
|
+
readonly content: SnapshotContentIdentity;
|
|
2598
|
+
readonly fieldPath: ReadonlyArray<string | number>;
|
|
2599
|
+
/** The original placed instance, or rich block id; null when not projected. */
|
|
2600
|
+
readonly instanceId: string | null;
|
|
2601
|
+
/** Paths are relative to this component's props, never document ids. */
|
|
2602
|
+
readonly link: (fieldPath: ReadonlyArray<string | number>) => string | null;
|
|
2603
|
+
readonly reference: (fieldPath: ReadonlyArray<string | number>) => SnapshotContentData | null;
|
|
2604
|
+
}
|
|
2605
|
+
|
|
2606
|
+
export declare type SnapshotConsentPurpose = Pick<ConsentPurpose, 'id' | 'version'>;
|
|
2607
|
+
|
|
2608
|
+
declare interface SnapshotContentData {
|
|
2609
|
+
readonly content: SnapshotContentIdentity;
|
|
2610
|
+
readonly context: FrontendOutputContext;
|
|
2611
|
+
readonly sourceLocale: string;
|
|
2612
|
+
readonly fallback: boolean;
|
|
2613
|
+
readonly values: Readonly<Record<string, unknown>>;
|
|
2614
|
+
readonly media: ReadonlyArray<FrontendMedia>;
|
|
2615
|
+
readonly presentation: SnapshotPresentation;
|
|
2616
|
+
readonly consentPurposes: ReadonlyArray<SnapshotConsentPurpose>;
|
|
2617
|
+
}
|
|
2618
|
+
|
|
2619
|
+
export declare interface SnapshotContentIdentity {
|
|
2620
|
+
readonly contentType: string;
|
|
2621
|
+
readonly documentId: string;
|
|
2622
|
+
readonly variantId: string;
|
|
2623
|
+
readonly revisionId: string;
|
|
2624
|
+
readonly revision: number;
|
|
2625
|
+
}
|
|
2626
|
+
|
|
2627
|
+
export declare interface SnapshotDocumentAssemblyCursor {
|
|
2628
|
+
readonly headerId: string;
|
|
2629
|
+
readonly tipId: string;
|
|
2630
|
+
}
|
|
2631
|
+
|
|
2632
|
+
export declare interface SnapshotDocumentAssemblyProgress extends SnapshotDocumentAssemblyCursor {
|
|
2633
|
+
readonly count: number;
|
|
2634
|
+
readonly bytes: number;
|
|
2635
|
+
}
|
|
2636
|
+
|
|
2637
|
+
export declare type SnapshotDocumentAssemblyRequest = Omit<CmsStaticPathRequest, 'localeIds' | 'owners'> & SnapshotPathSetSelection;
|
|
2638
|
+
|
|
2639
|
+
export declare type SnapshotDocumentTransferRequest = SnapshotAssetAssemblyRequest & {
|
|
2640
|
+
readonly id: string;
|
|
2641
|
+
};
|
|
2642
|
+
|
|
2643
|
+
export declare interface SnapshotMediaUse {
|
|
2644
|
+
readonly territory: string | null;
|
|
2645
|
+
readonly channel: string | null;
|
|
2646
|
+
readonly purpose: string | null;
|
|
2647
|
+
}
|
|
2648
|
+
|
|
2649
|
+
/** Verified private artifact from the server-selected provider root. All files
|
|
2650
|
+
* must be rehashed through EOF before this metadata can be returned. */
|
|
2651
|
+
export declare interface SnapshotOutputArtifact {
|
|
2652
|
+
readonly id: string;
|
|
2653
|
+
readonly manifest: {
|
|
2654
|
+
readonly version: 1;
|
|
2655
|
+
readonly subject: Readonly<Record<string, unknown>>;
|
|
2656
|
+
readonly files: ReadonlyArray<SnapshotOutputFile>;
|
|
2657
|
+
};
|
|
2658
|
+
}
|
|
2659
|
+
|
|
2660
|
+
export declare interface SnapshotOutputAssetsInput extends Pick<SnapshotOutputDocumentsInput, 'snapshotDigest' | 'inputsId' | 'executionId' | 'consentPurposes' | 'presentations' | 'documents'> {
|
|
2661
|
+
readonly web: {
|
|
2662
|
+
readonly id: string;
|
|
2663
|
+
readonly namespace: string;
|
|
2664
|
+
};
|
|
2665
|
+
}
|
|
2666
|
+
|
|
2667
|
+
export declare interface SnapshotOutputDocumentPin {
|
|
2668
|
+
readonly url: string;
|
|
2669
|
+
readonly path: string;
|
|
2670
|
+
readonly routeId: string;
|
|
2671
|
+
readonly artifactId: string;
|
|
2672
|
+
readonly presentation: SnapshotPresentation;
|
|
2673
|
+
}
|
|
2674
|
+
|
|
2675
|
+
export declare interface SnapshotOutputDocumentsInput {
|
|
2676
|
+
readonly snapshotDigest: string;
|
|
2677
|
+
readonly inputsId: string;
|
|
2678
|
+
readonly executionId: string;
|
|
2679
|
+
readonly selector: string;
|
|
2680
|
+
readonly pathSetIds: ReadonlyArray<string>;
|
|
2681
|
+
readonly consentPurposes: ReadonlyArray<SnapshotConsentPurpose>;
|
|
2682
|
+
readonly presentations: ReadonlyArray<SnapshotPresentation>;
|
|
2683
|
+
readonly documents: ReadonlyArray<SnapshotOutputDocumentPin>;
|
|
2684
|
+
}
|
|
2685
|
+
|
|
2686
|
+
export declare interface SnapshotOutputFile {
|
|
2687
|
+
readonly path: string;
|
|
2688
|
+
readonly digest: string;
|
|
2689
|
+
readonly size: number;
|
|
2690
|
+
readonly contentType: string;
|
|
2691
|
+
}
|
|
2692
|
+
|
|
2693
|
+
export declare interface SnapshotOutputFileChunk {
|
|
2694
|
+
readonly offset: number;
|
|
2695
|
+
readonly size: number;
|
|
2696
|
+
readonly digest: string;
|
|
2697
|
+
}
|
|
2698
|
+
|
|
2699
|
+
export declare interface SnapshotOutputFilePlan {
|
|
2700
|
+
readonly file: SnapshotOutputFile;
|
|
2701
|
+
readonly chunks: ReadonlyArray<SnapshotOutputFileChunk>;
|
|
2702
|
+
}
|
|
2703
|
+
|
|
2704
|
+
export declare interface SnapshotOutputProvider {
|
|
2705
|
+
/** Private physical transfer ports only. Their results grant no admission,
|
|
2706
|
+
* activation or serving authority; callers still own fresh authorization. */
|
|
2707
|
+
readonly planFile?: (input: {
|
|
2708
|
+
readonly id: string;
|
|
2709
|
+
readonly path: string;
|
|
2710
|
+
}) => Promise<SnapshotOutputFilePlan>;
|
|
2711
|
+
readonly readChunk?: (input: {
|
|
2712
|
+
readonly id: string;
|
|
2713
|
+
readonly file: SnapshotOutputFile;
|
|
2714
|
+
readonly chunk: SnapshotOutputFileChunk;
|
|
2715
|
+
}) => Promise<Uint8Array>;
|
|
2716
|
+
/** Trusted aggregation of the retained web bytes and actual renderer media.
|
|
2717
|
+
* The provider fixes all archive and output paths, independent of HTTP. */
|
|
2718
|
+
readonly composeAssets?: (input: SnapshotOutputAssetsInput) => Promise<{
|
|
2719
|
+
readonly id: string;
|
|
2720
|
+
readonly files: number;
|
|
2721
|
+
readonly bytes: number;
|
|
2722
|
+
}>;
|
|
2723
|
+
/** Read-only physical provenance from the fixed retained archive and actual
|
|
2724
|
+
* renderer inventories. No capture/stage/build is permitted. The enclosing
|
|
2725
|
+
* CMS reader still owns fresh grant, path and current-rights admission. */
|
|
2726
|
+
readonly readAssets?: (input: SnapshotOutputAssetsInput & {
|
|
2727
|
+
readonly id: string;
|
|
2728
|
+
}) => Promise<SnapshotOutputArtifact>;
|
|
2729
|
+
readonly begin: () => Promise<SnapshotOutputStage>;
|
|
2730
|
+
/** Required when composing controls from previously rendered documents. */
|
|
2731
|
+
readonly read?: (id: string) => Promise<SnapshotOutputArtifact>;
|
|
2732
|
+
/** Trusted physical composition of actual renderer receipts and verified
|
|
2733
|
+
* document bytes. The server fixes both source and destination custody. */
|
|
2734
|
+
readonly composeDocuments?: (input: SnapshotOutputDocumentsInput) => Promise<{
|
|
2735
|
+
readonly id: string;
|
|
2736
|
+
readonly documents: number;
|
|
2737
|
+
readonly bytes: number;
|
|
2738
|
+
}>;
|
|
2739
|
+
}
|
|
2740
|
+
|
|
2741
|
+
export declare interface SnapshotOutputStage {
|
|
2742
|
+
readonly write: (file: SnapshotOutputFile, bytes: AsyncIterable<Uint8Array>) => Promise<void>;
|
|
2743
|
+
readonly seal: (subject: Readonly<Record<string, unknown>>) => Promise<{
|
|
2744
|
+
readonly id: string;
|
|
2745
|
+
}>;
|
|
2746
|
+
readonly abort: () => Promise<void>;
|
|
2747
|
+
}
|
|
2748
|
+
|
|
2749
|
+
declare type SnapshotPart = typeof SNAPSHOT_PARTS[number];
|
|
2750
|
+
|
|
2751
|
+
declare interface SnapshotPartPin {
|
|
2752
|
+
readonly part: SnapshotPart;
|
|
2753
|
+
readonly format: string;
|
|
2754
|
+
readonly entries: number;
|
|
2755
|
+
readonly digest: string;
|
|
2756
|
+
}
|
|
2757
|
+
|
|
2758
|
+
declare interface SnapshotPathSetSelection {
|
|
2759
|
+
readonly pathSets: ReadonlyArray<{
|
|
2760
|
+
readonly id: string;
|
|
2761
|
+
readonly digest: string;
|
|
2762
|
+
}>;
|
|
2763
|
+
}
|
|
2764
|
+
|
|
2765
|
+
export declare interface SnapshotPresentation {
|
|
2766
|
+
readonly version: 1;
|
|
2767
|
+
readonly decided: boolean;
|
|
2768
|
+
readonly granted: ReadonlyArray<SnapshotConsentPurpose>;
|
|
2769
|
+
}
|
|
2770
|
+
|
|
2771
|
+
/** Cookie decoding belongs to the application. Retain the existing exact-version
|
|
2772
|
+
* consent decision, ignoring inherited properties and unknown purpose names. */
|
|
2773
|
+
export declare const snapshotPresentationFromChoices: (purposes: ReadonlyArray<SnapshotConsentPurpose>, choices: ConsentChoices | undefined) => SnapshotPresentation;
|
|
2774
|
+
|
|
2775
|
+
/** Complete finite public classes, including never-decided and explicit denial.
|
|
2776
|
+
* Refuse a build that cannot retain all classes within its declared budget. */
|
|
2777
|
+
export declare const snapshotPresentations: (purposes: ReadonlyArray<SnapshotConsentPurpose>, maximum?: number) => ReadonlyArray<SnapshotPresentation>;
|
|
2778
|
+
|
|
2779
|
+
export declare class SnapshotPresentationUnavailable extends SnapshotPresentationUnavailable_base {
|
|
2780
|
+
}
|
|
2781
|
+
|
|
2782
|
+
declare const SnapshotPresentationUnavailable_base: Schema.Class<SnapshotPresentationUnavailable, Schema.TaggedStruct<"SnapshotPresentationUnavailable", {
|
|
2783
|
+
readonly reason: Schema.Literals<readonly ["policy", "selection", "bounds"]>;
|
|
2784
|
+
}>, YieldableError>;
|
|
2785
|
+
|
|
2786
|
+
export declare interface SnapshotProjectionSelection {
|
|
2787
|
+
readonly id: string;
|
|
2788
|
+
readonly definitions: Readonly<Record<string, ContentProjectionDefinition | null>>;
|
|
2789
|
+
/** Explicit target types admitted for recursive native reference composition. */
|
|
2790
|
+
readonly referenceTypes?: ReadonlyArray<string>;
|
|
2791
|
+
/** Explicit target type → captured location mapping for native reference links. */
|
|
2792
|
+
readonly referenceRoutes?: Readonly<Record<string, string>>;
|
|
2793
|
+
/** Named captured trees with explicit scalar display fields and route mapping. */
|
|
2794
|
+
readonly trees?: Readonly<Record<string, SnapshotTreeSelection>>;
|
|
2795
|
+
}
|
|
2796
|
+
|
|
2797
|
+
/** Explicit decisions from the admitted app. Missing/null field values are a
|
|
2798
|
+
* separate decision; an unknown nonempty audience never becomes public. */
|
|
2799
|
+
export declare type SnapshotPublicAccess = {
|
|
2800
|
+
readonly kind: 'public';
|
|
2801
|
+
} | {
|
|
2802
|
+
readonly kind: 'deny';
|
|
2803
|
+
} | {
|
|
2804
|
+
readonly kind: 'field';
|
|
2805
|
+
readonly field: string;
|
|
2806
|
+
readonly values: ReadonlyArray<string>;
|
|
2807
|
+
readonly missing: 'public' | 'deny';
|
|
2808
|
+
};
|
|
2809
|
+
|
|
2810
|
+
export declare interface SnapshotRedirectTargetDocuments {
|
|
2811
|
+
readonly host: string;
|
|
2812
|
+
readonly documents: SnapshotSeoDocumentsSelection;
|
|
2813
|
+
}
|
|
2814
|
+
|
|
2815
|
+
export declare interface SnapshotRenditionRequirement extends RenditionDerivation {
|
|
2816
|
+
readonly contentType: string;
|
|
2817
|
+
readonly slot: string;
|
|
2818
|
+
}
|
|
2819
|
+
|
|
2820
|
+
export declare type SnapshotRoleTransferRequest = SnapshotAssetAssemblyRequest & {
|
|
2821
|
+
readonly role: SnapshotTransferRole;
|
|
2822
|
+
readonly id: string;
|
|
2823
|
+
readonly safety: {
|
|
2824
|
+
readonly artifactId: string;
|
|
2825
|
+
} | null;
|
|
2826
|
+
readonly targets: ReadonlyArray<SnapshotRedirectTargetDocuments>;
|
|
2827
|
+
};
|
|
2828
|
+
|
|
2829
|
+
export declare type SnapshotRouteClaim = {
|
|
2830
|
+
readonly kind: 'cms';
|
|
2831
|
+
} | {
|
|
2832
|
+
readonly kind: 'code';
|
|
2833
|
+
readonly collision: 'reject' | 'cms' | 'code';
|
|
2834
|
+
/** Opt this native page into public production documents and path sets. */
|
|
2835
|
+
readonly public?: boolean;
|
|
2836
|
+
};
|
|
2837
|
+
|
|
2838
|
+
/** Pure server-owned declaration selection from an already admitted snapshot.
|
|
2839
|
+
* No IO or application execution belongs in this synchronous callback. */
|
|
2840
|
+
export declare type SnapshotRouteDeclaration = CmsPublicRouteDeclaration | ((application: CmsBuildSnapshotApplicationPin & {
|
|
2841
|
+
readonly routeDiscovery: unknown;
|
|
2842
|
+
}) => CmsPublicRouteDeclaration);
|
|
2843
|
+
|
|
2844
|
+
export declare interface SnapshotRouteRead {
|
|
2845
|
+
readonly snapshotId: string;
|
|
2846
|
+
readonly snapshotDigest: string;
|
|
2847
|
+
readonly routeId: string;
|
|
2848
|
+
readonly path: string;
|
|
2849
|
+
readonly contentType: string;
|
|
2850
|
+
readonly localeId: string;
|
|
2851
|
+
readonly requestedLocale: string;
|
|
2852
|
+
readonly sourceLocale: string;
|
|
2853
|
+
readonly fallback: boolean;
|
|
2854
|
+
readonly values: Readonly<Record<string, unknown>>;
|
|
2855
|
+
readonly presentation: SnapshotPresentation;
|
|
2856
|
+
}
|
|
2857
|
+
|
|
2858
|
+
export declare interface SnapshotRoutingDefinition {
|
|
2859
|
+
readonly pagesDirectory: string;
|
|
2860
|
+
readonly claims: Readonly<Record<string, SnapshotRouteClaim>>;
|
|
2861
|
+
}
|
|
2862
|
+
|
|
2863
|
+
export declare interface SnapshotSeoDocumentsSelection extends SnapshotPathSetSelection {
|
|
2864
|
+
readonly artifactId: string;
|
|
2865
|
+
}
|
|
2866
|
+
|
|
2867
|
+
export declare type SnapshotTransferRole = 'assets' | 'deny' | 'redirects' | 'sitemap' | 'robots';
|
|
2868
|
+
|
|
2869
|
+
export declare interface SnapshotTreeData {
|
|
2870
|
+
readonly version: 1;
|
|
2871
|
+
readonly contentType: string;
|
|
2872
|
+
readonly localeId: string;
|
|
2873
|
+
readonly requestedLocale: string;
|
|
2874
|
+
readonly currentDocumentId: string | null;
|
|
2875
|
+
readonly nodes: ReadonlyArray<SnapshotTreeNode>;
|
|
2876
|
+
/** Root-first public ancestors of the current document, independent of includeField. */
|
|
2877
|
+
readonly ancestors: ReadonlyArray<SnapshotTreeNode>;
|
|
2878
|
+
}
|
|
2879
|
+
|
|
2880
|
+
export declare interface SnapshotTreeNode {
|
|
2881
|
+
readonly documentId: string;
|
|
2882
|
+
readonly parent: string | null;
|
|
2883
|
+
readonly depth: number;
|
|
2884
|
+
readonly path: string;
|
|
2885
|
+
readonly sourceLocale: string;
|
|
2886
|
+
readonly fallback: boolean;
|
|
2887
|
+
readonly values: Readonly<Record<string, unknown>>;
|
|
2888
|
+
}
|
|
2889
|
+
|
|
2890
|
+
export declare interface SnapshotTreeSelection {
|
|
2891
|
+
readonly contentType: string;
|
|
2892
|
+
readonly mappingId: string;
|
|
2893
|
+
readonly fields: ReadonlyArray<string>;
|
|
2894
|
+
/** Include only true nodes whose ancestors also match this Boolean field. */
|
|
2895
|
+
readonly includeField?: string;
|
|
2896
|
+
}
|
|
2897
|
+
|
|
2898
|
+
export declare interface StaticPathEntry {
|
|
2899
|
+
readonly host: string;
|
|
2900
|
+
readonly path: string;
|
|
2901
|
+
readonly localeId: string;
|
|
2902
|
+
readonly routeId: string;
|
|
2903
|
+
readonly owner: StaticPathOwner;
|
|
2904
|
+
readonly file: string | null;
|
|
2905
|
+
readonly sourceDigest: string | null;
|
|
2906
|
+
readonly parameters: Readonly<Record<string, string>>;
|
|
2907
|
+
}
|
|
2908
|
+
|
|
2909
|
+
export declare const staticPathHash: (value: unknown) => string;
|
|
2910
|
+
|
|
2911
|
+
export declare type StaticPathOwner = 'cms' | 'code';
|
|
2912
|
+
|
|
2913
|
+
declare interface StaticPathProgress {
|
|
2914
|
+
readonly version: 1;
|
|
2915
|
+
readonly phase: 'cms' | 'code' | 'seal' | 'ready';
|
|
2916
|
+
readonly after: string | null;
|
|
2917
|
+
readonly codeIndex: number;
|
|
2918
|
+
readonly revision: number;
|
|
2919
|
+
readonly inputPages: number;
|
|
2920
|
+
readonly inputCount: number;
|
|
2921
|
+
readonly inputBytes: number;
|
|
2922
|
+
readonly chain: string;
|
|
2923
|
+
}
|
|
2924
|
+
|
|
2925
|
+
export declare class StaticPathSetConflict extends StaticPathSetConflict_base {
|
|
2926
|
+
}
|
|
2927
|
+
|
|
2928
|
+
declare const StaticPathSetConflict_base: Schema.Class<StaticPathSetConflict, Schema.TaggedStruct<"StaticPathSetConflict", {
|
|
2929
|
+
readonly url: Schema.String;
|
|
2930
|
+
readonly owners: Schema.$Array<Schema.String>;
|
|
2931
|
+
readonly repair: Schema.String;
|
|
2932
|
+
}>, YieldableError>;
|
|
2933
|
+
|
|
2934
|
+
export declare interface StaticPathSetContext {
|
|
2935
|
+
readonly tenantId: string;
|
|
2936
|
+
readonly site: string;
|
|
2937
|
+
readonly environment: string;
|
|
2938
|
+
readonly snapshotId: string;
|
|
2939
|
+
readonly snapshotDigest: string;
|
|
2940
|
+
readonly releaseId: string | null;
|
|
2941
|
+
readonly consumerId: string;
|
|
2942
|
+
readonly buildId: string;
|
|
2943
|
+
readonly inputsId: string;
|
|
2944
|
+
readonly executionId: string;
|
|
2945
|
+
readonly routesDigest: string;
|
|
2946
|
+
readonly domainsDigest: string;
|
|
2947
|
+
readonly localesDigest: string;
|
|
2948
|
+
readonly policyDigest: string;
|
|
2949
|
+
readonly projectionDigest: string;
|
|
2950
|
+
readonly host: string;
|
|
2951
|
+
readonly localeIds: ReadonlyArray<string>;
|
|
2952
|
+
readonly owners: ReadonlyArray<StaticPathOwner>;
|
|
2953
|
+
}
|
|
2954
|
+
|
|
2955
|
+
export declare interface StaticPathSetEvidence {
|
|
2956
|
+
readonly set: SignedStaticPathSet;
|
|
2957
|
+
readonly pages: ReadonlyArray<ReadonlyArray<StaticPathEntry>>;
|
|
2958
|
+
}
|
|
2959
|
+
|
|
2960
|
+
export declare interface StaticPathSetManifest {
|
|
2961
|
+
readonly version: 1;
|
|
2962
|
+
readonly context: StaticPathSetContext;
|
|
2963
|
+
readonly sort: 'host-nfc-path/v1';
|
|
2964
|
+
readonly pageSize: 200;
|
|
2965
|
+
readonly count: number;
|
|
2966
|
+
readonly sources: {
|
|
2967
|
+
readonly count: number;
|
|
2968
|
+
readonly digest: string;
|
|
2969
|
+
};
|
|
2970
|
+
readonly pages: ReadonlyArray<{
|
|
2971
|
+
readonly count: number;
|
|
2972
|
+
readonly digest: string;
|
|
2973
|
+
readonly first: string;
|
|
2974
|
+
readonly last: string;
|
|
2975
|
+
}>;
|
|
2976
|
+
}
|
|
2977
|
+
|
|
2978
|
+
export declare class StaticPathSetUnavailable extends StaticPathSetUnavailable_base {
|
|
2979
|
+
}
|
|
2980
|
+
|
|
2981
|
+
declare const StaticPathSetUnavailable_base: Schema.Class<StaticPathSetUnavailable, Schema.TaggedStruct<"StaticPathSetUnavailable", {
|
|
2982
|
+
readonly reason: Schema.Literals<readonly ["input", "bounds", "integrity", "key", "cursor", "state", "changed"]>;
|
|
2983
|
+
}>, YieldableError>;
|
|
2984
|
+
|
|
2985
|
+
/** A type's taxonomy — see `ContentTypeSpec.taxonomy`. */
|
|
2986
|
+
declare interface TaxonomyConfig {
|
|
2987
|
+
/** A declared `Schema.Array(Schema.String)` field. */
|
|
2988
|
+
readonly field: string;
|
|
2989
|
+
readonly terms: ReadonlyArray<VocabularyTerm>;
|
|
2990
|
+
/** A term outside the vocabulary: `refuse` (default) fails the save, `keep` keeps it as typed. */
|
|
2991
|
+
readonly unknown?: 'refuse' | 'keep';
|
|
2992
|
+
}
|
|
2993
|
+
|
|
2994
|
+
/** Declared on a content type as `templates`. */
|
|
2995
|
+
declare interface TemplatesConfig {
|
|
2996
|
+
/** An optional string field that stores the template's id. */
|
|
2997
|
+
readonly field: string;
|
|
2998
|
+
/** The `Schema.Components` field the rules apply to. */
|
|
2999
|
+
readonly components: string;
|
|
3000
|
+
/** The component prop that holds a placement's width (`widths`); default `width`. */
|
|
3001
|
+
readonly width?: string;
|
|
3002
|
+
readonly list: ReadonlyArray<PageTemplate>;
|
|
3003
|
+
}
|
|
3004
|
+
|
|
3005
|
+
/** How a content type forms a tree. Validated by `defineContentType`. */
|
|
3006
|
+
declare interface TreeConfig {
|
|
3007
|
+
/** An optional `Schema.Reference(<this type>)` field: the parent document. */
|
|
3008
|
+
readonly parent: string;
|
|
3009
|
+
/** An optional number field ordering siblings (ascending; unset sorts last). */
|
|
3010
|
+
readonly order?: string;
|
|
3011
|
+
/** The string field that is this node's path segment — usually the slug. */
|
|
3012
|
+
readonly segment: string;
|
|
3013
|
+
/**
|
|
3014
|
+
* Optional fields a page takes from the nearest ancestor that sets them
|
|
3015
|
+
* (a header, a footer): read with {@link inheritedValue}. `locked: true`
|
|
3016
|
+
* means no page may set it — only whatever the app supplies above the
|
|
3017
|
+
* tree (a site default).
|
|
3018
|
+
*/
|
|
3019
|
+
readonly inherit?: Readonly<Record<string, InheritRule>>;
|
|
3020
|
+
}
|
|
3021
|
+
|
|
3022
|
+
/** One upload, no retries. backendOrigin is trusted deployment configuration,
|
|
3023
|
+
* never request-selected. On a lost acknowledgement, inspect the original
|
|
3024
|
+
* deployment through the JSON client before deciding whether to send again.
|
|
3025
|
+
* The source factory runs only after initial admission and must honor its
|
|
3026
|
+
* supplied signal while awaiting IO. Transfer completion/refusal cancels it. */
|
|
3027
|
+
export declare const uploadCmsBuildApplication: (options: {
|
|
3028
|
+
readonly backendOrigin: string;
|
|
3029
|
+
readonly credential: string;
|
|
3030
|
+
readonly admission: CmsBuildApplicationAdmission;
|
|
3031
|
+
readonly bytes: (signal: AbortSignal) => AsyncIterable<Uint8Array>;
|
|
3032
|
+
readonly authorize: () => Promise<void>;
|
|
3033
|
+
readonly signal: AbortSignal;
|
|
3034
|
+
/** Trusted server-owned transport; endpoint and all upload guards stay fixed. */
|
|
3035
|
+
readonly fetch?: typeof globalThis.fetch;
|
|
3036
|
+
}) => Promise<CmsBuildApplicationAdmission>;
|
|
3037
|
+
|
|
3038
|
+
/** Check each immutable page independently against its signed root and count. */
|
|
3039
|
+
export declare const verifyStaticPathPage: (set: SignedStaticPathSet, index: number, value: unknown) => ReadonlyArray<StaticPathEntry>;
|
|
3040
|
+
|
|
3041
|
+
/** One term and the spellings that mean it. */
|
|
3042
|
+
declare interface VocabularyTerm {
|
|
3043
|
+
readonly term: string;
|
|
3044
|
+
readonly synonyms?: ReadonlyArray<string>;
|
|
3045
|
+
}
|
|
3046
|
+
|
|
3047
|
+
declare interface WorkflowStep {
|
|
3048
|
+
/** camelCase, unique within the workflow. */
|
|
3049
|
+
readonly id: string;
|
|
3050
|
+
readonly label: string;
|
|
3051
|
+
/** The scope a person needs to decide this step (a delegate decides without it). */
|
|
3052
|
+
readonly approverScope: string;
|
|
3053
|
+
/** Steps that must be approved before this one opens. */
|
|
3054
|
+
readonly after?: ReadonlyArray<string>;
|
|
3055
|
+
/** The step applies only when this holds for the revision's values. */
|
|
3056
|
+
readonly when?: (values: Readonly<Record<string, unknown>>) => boolean;
|
|
3057
|
+
/** Hours the step may stay open once it is open; later it is overdue. */
|
|
3058
|
+
readonly slaHours?: number;
|
|
3059
|
+
/** Approving needs evidence: a link or a note saying what was checked. */
|
|
3060
|
+
readonly evidence?: boolean;
|
|
3061
|
+
}
|
|
3062
|
+
|
|
3063
|
+
export { }
|