/** One file from the export's `source/`, keyed by its path RELATIVE to that directory. */ export interface ExportSourceFile { /** Forward-slash separated, e.g. `Game.ts` or `levels/level-2.json`. */ path: string; contents: Uint8Array; } export interface CreatorExport { /** The game's id on the Creator's api-server — the row a CLI project can adopt. */ gameId: string; genre: string; /** The engine the game was last edited against, or null when the export predates the field. */ engineVersion: string | null; /** The Creator template the game began from (`metadata.importedFrom`), or null. */ template: string | null; /** `game.json`'s `gameName`, for the summary. Null when absent or unreadable. */ gameName: string | null; /** Every file under `/source/`, with `.git` already dropped. */ sourceFiles: ExportSourceFile[]; } /** * Read and validate the export at `zipPath`. * * Every failure is a CliError naming the file, because all of them mean the same thing to a * creator: this is not an export the CLI can convert, and nothing has been written yet. */ export declare function readCreatorExport(zipPath: string): CreatorExport; /** * The hosts serving assets that belong to THIS game — http(s) URLs in `world.json` and * `game.json` whose path carries the game's own id. * * Read for one reason: a game's assets are minted under `worlds/v3//` by the api-server * that hosts the Creator, and so is the game row a CLI project adopts by id. Importing a dev game * into a project pinned to prod produces something that builds, runs and then fails every server * command with a flat "not found or is not owned by the caller" — the one failure this conversion * can see coming and the creator cannot. The caller compares these against the environment it * resolved; nothing here decides anything. * * **The gameId filter is the whole point, not a refinement.** Every game — on every environment — * references shared defaults that live on prod: `mini.bitmagic.ai/worlds/v3/BaseCharacter.glb` is * in the game.json of a dev game and a prod game alike. Classifying on "any bitmagic host" reads * that one line and calls every dev export a prod game, which is precisely the mistake this check * exists to prevent. Only a URL carrying the game's own id was minted for this game, by the * api-server that owns it. * * Named for what it returns rather than `assetHosts`, which is `mobile/asset-hosts.ts` — a * different question (which hosts the LAN bridge proxies for a phone) about the same URLs. */ export declare function gameAssetHosts(source: CreatorExport): string[];