import type { CliCredentials } from '../config'; import { checkAddOn, type AddOnCheckReport } from './addon'; import type { DriveEffect } from './drive'; import { type MakeItemRequest, type PackagePin } from './mintVehicle'; import { type BytesFetch, type Json, type Requester } from './platform'; import { type SealIssue } from './sealCheck'; import type { ContinuumObjects } from './publish'; export { ADDON_DEFINITION_SCHEMA, addOnDefinition } from './addOnDefinition'; export declare const ADDON_MODEL_ROLE = "addon.model.web"; export interface AddOnMintOptions { dir: string; glb?: string; contentRating?: string; out?: string; /** Package Version to seal (default addon.json `version`, else 1.0.0). With `--item`, the NEW version of that part. */ version?: string; /** Publish a NEW VERSION of this existing add-on Item instead of minting one. */ itemId?: string; /** 1-500 chars; the version move's audit reason (default names the version). */ reason?: string; /** Run the full check and the seal-side validation only; nothing is uploaded. */ dryRun?: boolean; } export interface AddOnMintLedger { schema: 'helix.vehicle-addon-mint-ledger/1'; intentId: string; glb?: { sha: string; bytes: number; } | null; rootSha?: string; pin?: PackagePin; itemId?: string; versionMove?: 'moved' | 'staged-awaiting-visual-qa'; steps: Array<{ at: string; step: string; detail?: unknown; }>; } export interface AddOnMintResult { ok: boolean; dryRun: boolean; check: AddOnCheckReport; itemId?: string; packagePin?: PackagePin | null; tuneOnly?: boolean; /** `minted` (first publish), `moved` (a new Version of an existing Item), or sealed but waiting on visual QA. */ versionMove?: 'minted' | 'moved' | 'staged-awaiting-visual-qa'; /** Seal-side refusals found before anything was uploaded (provenance, rating, Package shape, version clash). */ seal?: SealIssue[]; readBack?: { pinned: boolean; fitsHosts: Record; listedOnHosts: Record; status: string; }; files: { ledger: string; definition?: string; descriptor?: string; receipt?: string; }; next: string[]; } export interface AddOnMintDeps { api: Requester; objects: ContinuumObjects; publishPackage(intent: Json): Promise; makeItem(input: MakeItemRequest): Promise<{ item: { id: string; slug?: string; packagePin: PackagePin; }; }>; fetchBytes?: BytesFetch; measureDrive?: (vehiclePackage: Json, ops: Json[], slotType: string) => Promise; /** Injectable for tests; defaults to the real `checkAddOn`. */ check?: typeof checkAddOn; onProgress?: (message: string) => void; } /** * The exact Package publication intent an add-on seal sends, built from values only (no network, no upload) so the real * publish and the dry run's seal-side validation judge the SAME object. `glb` is null for a tune-only part. */ export declare function addOnSealIntent(a: { packageId: string; slug: string; name: string; version: string; rootBytes: Uint8Array; rootSha: string; glb: { sha: string; bytes: number; } | null; slotType: string; provenance?: { kind?: string; source?: string; }; dirName: string; stage: boolean; }): { intent: Json; objects: Json[]; }; export declare function mintVehicleAddOn(opts: AddOnMintOptions, creds: CliCredentials, deps: AddOnMintDeps): Promise; export declare function formatAddOnMint(r: AddOnMintResult, checkText: string): string;