# `SceneSpec`

> Contract 2.0.0 · package sha256 `a857eca95b35921109faf997094bb4192f12527d9d0fcd4be7e97f06425bad6e` · generated from `configurator-runtime.d.ts` by `services/onsite-scripter/scripts/build-contract-docs.mjs`; edit the source, not this file.

Interface · `import type { SceneSpec } from '@holostep-configurators/runtime-client/contract';` · stable · since 2.0.0 · section 9. Stage

The look as one JSON document: what [`apply()`](Writer.apply.md) writes ([`state().look`](SessionState.look.md) reads it back as a
[`LookState`](LookState.md)). App code
produces it; 2.0 stores none of it. In [`apply()`](Writer.apply.md), an omitted key means "unchanged".

## Members

| Member | Kind | Summary |
| --- | --- | --- |
| <a id="_schema"></a>[`$schema?`](SceneSpec._schema.md) | property | The JSON Schema id, for editors and [`validate('scene')`](validate.md). |
| <a id="materials"></a>[`materials?`](SceneSpec.materials.md) | property | Named materials, referenced from rules and items as `{ ref: name }`. |
| <a id="rules"></a>[`rules?`](SceneSpec.rules.md) | property | [`apply()`](Writer.apply.md)'s own block of rules, applied in array order, before every rule made through [`find().set`](PartActions.set.md) (those form a later block that [`apply()`](Writer.apply.md) never removes). |
| <a id="collections"></a>[`collections?`](SceneSpec.collections.md) | property | Listed collections are reconciled, in call order with each one's `set()` and `load()` (spec section 6.10, R4); unlisted live collections are left alone. |

## Declaration

```ts
export interface SceneSpec {
  $schema?: 'holostep.scene/1';
  materials?: Readonly<Record<string, MaterialSpec>>;
  rules?: readonly RuleSpec[];
  collections?: Readonly<Record<string, CollectionSpec & {
    role?: Role;
  }>>;
}
```

## Generic-API test (spec 3.1)

| Rule | Result |
| --- | --- |
| 1. Neutral name | pass: `SceneSpec` names no product |
| 2. A precedent | not recorded: no ledger row (coverage.json) names this member or its owner |
| 3. Two apps, or labs | pass: 5 apps (fleet cross-check: app-378d190f1b, app-4f16d2f6da, app-510d750508, app-ceb4eccc72, app-fb16dd1985) |
| 4. The cheaper fix first | not recorded per member (Appendix B decides it per need) |
