import { type ContinuumPackage, type ContinuumPackageVersion } from '@hypersoniclabs/helix-manifest'; import type { ContinuumPublicationIntent } from '../continuum/types'; import type { WorldRelease } from '@hypersoniclabs/helix-manifest'; /** * Builds the Continuum Package and Package Version for a cooked Unreal World. * * Ported, not designed: the shape below is the one helix-manifest's own * unreal-world.spec.ts builds, and everything is handed to their * `validateContinuumPackageVersion` before it leaves this function. * * The cooked-role document is a real helix-manifest contract * (`helix.continuum.unreal-cooked-role/1`): the descriptor's `roles[].manifest` * pins the canonical-JSON CID and byte length of a document whose `files[]` * entries are the cooked-file object references. There is deliberately no * top-level `unrealWorld.objects[]` aggregate, so the exact closure is derived * from those documents: `expectedClosure` must name every cooked byte the * World owns or the backend seal (and the runtime capability grant) would omit * it. The 1.86 GB UCAS is never read here; only the small role documents are. */ export type UnrealPackageOptions = { publishDir: string; packageId: string; version: string; name?: string; /** * Local file path for every object CID in the descriptor closure. When a * cooked-role document's CID is present it is used to derive the exact * cooked-file closure; otherwise the SDK layout * `continuum/roles/.json` under `publishDir` is used. */ objectPaths?: Record; }; export type UnrealPackageResult = { package: ContinuumPackage; packageVersion: ContinuumPackageVersion; /** * Retained for compatibility. The cooked-role document is defined upstream * now (`CONTINUUM_UNREAL_COOKED_ROLE_SCHEMA`), so this is always false. */ roleObjectIsUndefinedUpstream: boolean; }; export declare function buildUnrealPackageVersion(options: UnrealPackageOptions): Promise; /** * Assembles the Continuum publication intent for a cooked Unreal World. * * The point of this function is that it does NOT publish. `ContinuumPublisher` * already owns the job -- objects, package, version, lease, seal, listings and * the World Release -- with checkpointing and resume. Reimplementing any of it * for Unreal would be the divergence this work exists to avoid, so the Unreal * lane's whole contribution is producing a legal intent and handing it over. * * Every object is published from the ACTUAL file on disk: the canonical cooked * role manifest documents and each per-file cooked object derived from each * role document's `files[].object`. There is no `instant-world-adoption` here * and no `unrealWorld.objects[]` aggregate. Role JSON is read under a strict * small bound and must hash, byte for byte, to the CID the sealed descriptor * pins; non-JSON cooked files are SHA-256 streamed so a 1.86 GB UCAS is never * buffered. A mismatch fails closed rather than publishing bytes under an * aggregate digest. */ export type UnrealIntentOptions = UnrealPackageOptions & { projectId: string; sourceDigest: string; visibility?: 'private' | 'public'; world?: { release: WorldRelease; defaultRuntimeProfileId: string; }; /** * Local file path for every object CID in the descriptor closure: each * `unrealWorld.roles[].manifest` cooked-role document AND every cooked file * its `files[].object` references. The bytes are read and their CID is * verified against the descriptor. */ objectPaths: Record; }; export declare function buildUnrealPublicationIntent(options: UnrealIntentOptions): Promise<{ intent: ContinuumPublicationIntent; roleObjectIsUndefinedUpstream: boolean; }>;