/** * Published add-on check: does the WEB CUSTOMIZER accept this add-on Item? Reads the Item's exact Package pin, the public * Continuum manifest and (for a meshless part) its root object, then runs the customizer's own judgement: * * - a variant with mediaType model/gltf-binary on a web runtime profile (`web-balanced`, else legacy `web`, else a * single other `web*` profile) is an equippable mesh; * - no such variant: the part must be deliberately meshless, which `meshlessAddOnManifestError` (the Package shape) * and `meshlessAddOnDefinitionError` (the parsed root) decide — the vendored guard shared byte for byte with * helixgame.com `lib/continuum/item-model.ts` (`assertVerifiedMeshlessAddOn`). * * Round 8 sold four tune-only F40 parts that every pre-publish check called fit while the customizer refused them; * this is the check that would have said so. Public reads only: no sign-in. */ import { type Requester } from './platform'; import { type VehicleIssue } from './validate'; /** The customizer's runtime profile ids (helixgame.com lib/continuum/item-model.ts). */ export declare const CUSTOMIZER_WEB_PROFILE = "web-balanced"; export declare const CUSTOMIZER_LEGACY_WEB_PROFILE = "web"; export type PublishedAddOnMode = 'mesh' | 'meshless' | 'refused'; export interface PublishedAddOnVerdict { itemId: string; title?: string; slotType?: string | null; mode: PublishedAddOnMode; /** True when the customizer will equip and save the part. */ ok: boolean; /** The customizer's exact refusal text (or why the Package could not be read), when not ok. */ error?: string; pin?: { packageId: string; version: string; manifestCid: string; } | null; /** The web GLB the customizer would draw, when mode is `mesh`. */ meshCid?: string; rootCid?: string; /** Findings about this part's host-frame bind against the host car's own nodes (the runtime throws on a missing one). */ hostFrameIssues?: VehicleIssue[]; } export interface PublishedDeps { /** Public GET reads (`/api/v1/universal-items/`, `/api/v1/continuum/public/packages//versions/`). */ api: Requester; apiUrl: string; /** Read a public Continuum object's exact bytes by sha256. Defaults to `fetchPublicObject`. */ readObject?: (sha: string) => Promise; } /** A sign-in-free `Requester`: GET only, JSON. */ export declare function publicRequester(apiUrl: string, fetchImpl?: typeof fetch): Requester; interface ManifestVariant { runtimeProfileId?: string; object?: { cid?: string; role?: string; mediaType?: string; }; } /** The customizer's `selectWebGltfBinaryVariant`: the variant it would draw, null when there is none, or the refusal. */ export declare function selectCustomizerWebVariant(variants: readonly ManifestVariant[]): { selected: ManifestVariant | null; error?: string; }; /** Run exactly what the customizer runs for one add-on Item. Never throws for a refusal; a read failure is a refusal too. */ export declare function checkPublishedAddOn(itemId: string, deps: PublishedDeps): Promise; export interface HostAddOnsReport { hostId: string; total: number; truncated: boolean; verdicts: PublishedAddOnVerdict[]; ok: boolean; /** The host car's own bind contract (the lid mount nodes and the host-frame root an offered boot/bonnet socket needs). */ hostFrame?: { source?: string; issues: VehicleIssue[]; }; } /** Check every add-on on a host's rail (`GET /universal-items//add-ons`) with the customizer's own judgement. */ export declare function checkHostAddOns(hostId: string, deps: PublishedDeps): Promise; export declare function formatPublishedVerdict(v: PublishedAddOnVerdict): string; export declare function formatHostAddOns(r: HostAddOnsReport): string; export {};