Open-source platform for 3D AI agents. Turn text or a photo into a rigged, animated GLB avatar, give it an LLM brain, memory and a wallet, and embed it anywhere with one web component. Remote MCP server, x402 payments, Three.js, browser-native.
JavaScript 3d-generationai-agentsanimationavatardigital-humangenerative-aiglbgltfimage-to-3dllmmcpmcp-servermodel-context-protocolsolanatext-to-3dthreejsweb-componentswebglwebxrx402
feat(engine-bridges): validate and package the Unity, Godot and Unreal bridges as deterministic store uploads
nirholasfb749a0a21af
diff --git a/STRUCTURE.md b/STRUCTURE.mdindex 4b6f1a1f7..a83276422 100644--- a/STRUCTURE.md+++ b/STRUCTURE.md@@ -175,7 +175,7 @@ packages, a generated standalone GitHub mirror). See| Verifiable 3D provenance (content credentials, signed by default) | Spec [specs/PROVENANCE_3D.md](specs/PROVENANCE_3D.md), pure core [api/_lib/provenance-3d.js](api/_lib/provenance-3d.js), automatic issuance [api/_lib/auto-provenance.js](api/_lib/auto-provenance.js), Solana anchor [api/_lib/provenance-anchor.js](api/_lib/provenance-anchor.js), MCP tools [api/_mcp3d/tools/provenance.js](api/_mcp3d/tools/provenance.js) (`verify_provenance` free, `anchor_provenance` paid $0.05), free REST verify [api/provenance.js](api/provenance.js) `→ /api/provenance`, model page + viewer badge ([src/model-page.js](src/model-page.js), [public/viewer.html](public/viewer.html)), docs [docs/provenance.md](docs/provenance.md). | Live (verify + automatic signing) · anchor gated on issuer key + devnet funds | C2PA-style signed content credentials for AI 3D: creator, prompt, model/provider, lineage, timestamp, and the GLB's sha256, ed25519-signed by the three.ws issuer. Every forge-generated GLB (every lane: free NIM, Forge Pro, rigged avatars, self-host, async GCP workers) and every x402 paid-asset download gets this credential automatically and free, with no anchor and no spend, keyed by content hash so a credential is only ever issued once per file; the owner can turn it off with `PROVENANCE_AUTO_DISABLE=true`. Free public `verify_provenance` / `GET /api/provenance?src=…` recompute the hash and return `verified | tampered | unknown` (a single changed byte → tampered); the verify path and response are coin-clean (both stores). `anchor_provenance` remains a separate paid upgrade that additionally writes the SPL Memo anchor. Tests: [tests/provenance-3d.test.js](tests/provenance-3d.test.js), [tests/auto-provenance.test.js](tests/auto-provenance.test.js). Evidence: [prompts/store-submissions/_generated/provenance/](prompts/store-submissions/_generated/provenance/). Store-submission prompt 19, automatic-by-default prompt 079. || Simulation readiness (a physics grade for 3D assets) | Spec [specs/SIM_READINESS.md](specs/SIM_READINESS.md), pure core [api/_lib/sim-readiness.js](api/_lib/sim-readiness.js), storage [api/_lib/sim-readiness-store.js](api/_lib/sim-readiness-store.js) + migration [20260813180000_sim_readiness_grades.sql](api/_lib/migrations/20260813180000_sim_readiness_grades.sql), free MCP tool [api/_mcp3d/tools/sim-readiness.js](api/_mcp3d/tools/sim-readiness.js) (`grade_sim_readiness`), free REST [api/sim-readiness.js](api/sim-readiness.js) `→ /api/sim-readiness`, shared badge + details panel [public/sim-readiness-panel.js](public/sim-readiness-panel.js) (`<sim-readiness>`, used by [public/viewer.html](public/viewer.html) and [src/model-page.js](src/model-page.js)), write path in [api/_lib/forge-store.js](api/_lib/forge-store.js) `materializeCreation`, docs [docs/sim-readiness.md](docs/sim-readiness.md). | Live | The question a renderer never asks and a rigid-body solver always does: can this mesh be simulated as-is? Four verdicts (`simulation_ready`, `needs_scale`, `needs_repair`, `unusable`, plus `unreadable` for non-glTF bytes) over measurements derived entirely from the geometry: watertightness and winding via welded-position topology, real-world extents read as meters per the glTF unit convention, exact volume/centroid/inertia from the divergence theorem and tetrahedron covariance, and a convex-hull proxy with its convexity ratio. Nothing is guessed: where a value cannot be known from the mesh (true scale, density) the report says so. Grades are keyed by GLB content hash, not URL, so one row serves the forge creation, the Object Library entry, a remix and an arbitrary third-party URL; every finished generation is graded on the write path, so a model page renders its verdict with no extra request. Signed into the content credential as `simReadiness` (provenance v2), which is what makes the physics claim as forge-proof as the authorship claim. Free, no account, no coin surface, both stores. Tests: [tests/sim-readiness.test.js](tests/sim-readiness.test.js), [tests/api/sim-readiness-endpoint.test.js](tests/api/sim-readiness-endpoint.test.js), [tests/provenance-3d.test.js](tests/provenance-3d.test.js). || Engine QA (a real-time-engine fitness grade) | Isomorphic core [api/_lib/engine-qa-core.js](api/_lib/engine-qa-core.js) (thresholds + verdict math, zero imports), server grader [api/_lib/engine-qa.js](api/_lib/engine-qa.js), browser-only partial grader [src/engine-qa-client.js](src/engine-qa-client.js), free REST [api/3d/engine-qa.js](api/3d/engine-qa.js) `→ /api/3d/engine-qa` (`?lods=1` builds a real LOD chain first, `?format=stl` exports a watertight mesh), shared badge + details panel [public/engine-qa-panel.js](public/engine-qa-panel.js) (`<engine-qa>`, used by [public/viewer.html](public/viewer.html) and Rig Doctor's [src/rig-doctor-page.js](src/rig-doctor-page.js)), LOD chain builder [packages/glb-tools/src/lod.js](packages/glb-tools/src/lod.js) (`buildLodChain`, real meshoptimizer decimation tagged `MSFT_lod`), opt-in generation variant in [api/_lib/forge-store.js](api/_lib/forge-store.js) (`buildLodVariant`, wired through [api/_lib/forge-options.js](api/_lib/forge-options.js)'s `lods` option) + migration [20261015020000_forge_lod_variant.sql](api/_lib/migrations/20261015020000_forge_lod_variant.sql), docs [docs/engine-qa.md](docs/engine-qa.md) `→ /docs/engine-qa`. | Live | The question a game engine's import step asks that neither glTF validation nor [simulation readiness](docs/sim-readiness.md) answers: will this run at 60fps, and can it collide cheaply? Five checks, each `pass`/`warn`/`fail`/`skip`, overall the worst non-skip verdict: draw calls (real scene-graph walk, one per node+primitive pair actually reachable from the root, so instancing counts correctly), material count, texel density (texels per meter of real-world surface, `skip` honestly when nothing is UV-mapped to a texture), a per-LOD-level triangle budget plus the monotonic-decrease rule a chain must satisfy, and collider suitability (reuses the print pipeline's watertight/manifold analyzer). The thresholds and verdict math live in one zero-dependency core so the server grader and Rig Doctor's zero-network browser pass can never disagree. The same `buildLodChain` pipeline backs an on-demand upgrade in the panel and an opt-in `{ lods: true }` generation option that stores a combined `MSFT_lod` GLB as a third object alongside the delivered mesh, fire-and-forget, same pattern as the existing web-delivery variant. Tests: [tests/engine-qa-core.test.js](tests/engine-qa-core.test.js), [tests/engine-qa.test.js](tests/engine-qa.test.js), [tests/engine-qa-client.test.js](tests/engine-qa-client.test.js), [tests/forge-options.test.js](tests/forge-options.test.js), [tests/forge-store-materialize.test.js](tests/forge-store-materialize.test.js). |-| Engine bridges (Unity, Godot, Unreal) | Shared contract [specs/ENGINE_BRIDGE.md](specs/ENGINE_BRIDGE.md), Unity UPM package [packages/unity-bridge](packages/unity-bridge) (`ThreeWsClient.cs` + `ThreeWsForgeImporter.cs` on [glTFast](https://github.com/atteneder/glTFast)), Godot addon [packages/godot-bridge](packages/godot-bridge) (`three_ws_client.gd` + `forge_importer.gd` on Godot's native `GLTFDocument`), Unreal plugin [packages/unreal-bridge](packages/unreal-bridge) (`FThreeWsClient` + `FThreeWsForgeImporter` on Unreal's Interchange glTF pipeline), docs [docs/engine-bridges.md](docs/engine-bridges.md) `→ /docs/engine-bridges`. | Live (Unity, Godot) · Unreal plugin ships source-complete, untestable in this environment (no license-free headless Unreal install) | One prompt-to-mesh contract, three independent implementations, each calling only the public Forge API: `POST /api/forge` to submit, `GET /api/forge?job=<id>` to poll (server-side failover keeps the same job id even if the lane dies mid-run), a plain HTTPS GET to download. Anonymous by default via a per-instance `x-forge-client` handle, same free-first routing every other caller gets; set a provider key for BYOK. The same four shared import settings (`generate_colliders`, `import_materials`, `scale`, `destination`) map onto each engine's own equivalent: a convex `MeshCollider` in Unity, a `ConvexPolygonShape3D` in Godot, a bounding-box `UBodySetup` in Unreal. Each package ships an editor window/dock (Unity: `Window > three.ws > Forge Bridge`; Godot: the **three.ws Forge** dock; Unreal: `Window > three.ws Forge Bridge`) plus a runnable example and a README. Godot's `test/smoke_test.gd` runs the full flow headlessly against the live API (`godot --headless --script test/smoke_test.gd`); Unity and Unreal require a licensed GUI install to exercise, so they're verified by code review against the shared contract instead. |+| Engine bridges (Unity, Godot, Unreal) | Shared contract [specs/ENGINE_BRIDGE.md](specs/ENGINE_BRIDGE.md), Unity UPM package [packages/unity-bridge](packages/unity-bridge) (`ThreeWsClient.cs` + `ThreeWsForgeImporter.cs` on [glTFast](https://github.com/atteneder/glTFast)), Godot addon [packages/godot-bridge](packages/godot-bridge) (`three_ws_client.gd` + `forge_importer.gd` on Godot's native `GLTFDocument`), Unreal plugin [packages/unreal-bridge](packages/unreal-bridge) (`FThreeWsClient` + `FThreeWsForgeImporter` on Unreal's Interchange glTF pipeline), docs [docs/engine-bridges.md](docs/engine-bridges.md) `→ /docs/engine-bridges`. | Live (Unity, Godot) · Unreal plugin ships source-complete, untestable in this environment (no license-free headless Unreal install) | One prompt-to-mesh contract, three independent implementations, each calling only the public Forge API: `POST /api/forge` to submit, `GET /api/forge?job=<id>` to poll (server-side failover keeps the same job id even if the lane dies mid-run), a plain HTTPS GET to download. Anonymous by default via a per-instance `x-forge-client` handle, same free-first routing every other caller gets; set a provider key for BYOK. The same four shared import settings (`generate_colliders`, `import_materials`, `scale`, `destination`) map onto each engine's own equivalent: a convex `MeshCollider` in Unity, a `ConvexPolygonShape3D` in Godot, a bounding-box `UBodySetup` in Unreal. Each package ships an editor window/dock (Unity: `Window > three.ws > Forge Bridge`; Godot: the **three.ws Forge** dock; Unreal: `Window > three.ws Forge Bridge`) plus a runnable example and a README. Godot's `test/smoke_test.gd` runs the full flow headlessly against the live API (`godot --headless --script test/smoke_test.gd`); Unity and Unreal require a licensed GUI install to exercise, so they're verified by code review against the shared contract instead. Store packaging: `npm run package:engine-stores` ([scripts/package-engine-bridges.mjs](scripts/package-engine-bridges.mjs)) validates each bridge and builds a deterministic upload zip for the Unity Asset Store, Godot Asset Library and Fab from the listing metadata in [docs/engine-store-listings/](docs/engine-store-listings); the owner submits, see [docs/engine-store-publishing.md](docs/engine-store-publishing.md). || OpenAI Select Partner (partner surface + announcement pack) | [pages/openai/index.html](pages/openai/index.html) `→ /openai`, badge assets [public/partners/openai/](public/partners/openai), announcement [blog/three-ws-openai-select-partner.html](blog/three-ws-openai-select-partner.html) `→ /blog/three-ws-openai-select-partner`, directory card in [pages/partners.html](pages/partners.html) `→ /partners`, press/social pack [marketing/openai-select-partner/](marketing/openai-select-partner/README.md), original OpenAI-supplied badge files + press-release template [OAI Select Tier Assets/](OAI%20Select%20Tier%20Assets/README.md) | Live | three.ws's OpenAI Partner Network Select-tier surface. `/openai` is the partner landing: the supplied badge (used unmodified, on a white plate), the four live OpenAI surfaces (the free keyless [3D Studio MCP connector](docs/mcp-studio.md) `→ /api/mcp-studio`, the custom-GPT Actions twin `→ /api/3d/studio`, [Spatial MCP](specs/SPATIAL_MCP.md), and [AR in ChatGPT](docs/chatgpt-ar.md)), the connect table, and the eleven-tool list. The marketing pack holds badge-usage rules and the press-release draft, which is gated on OpenAI's written approval before publishing (see its README). || NVIDIA Inception (membership surface + GPU docs cluster) | Landing page [pages/nvidia/index.html](pages/nvidia/index.html) `→ /nvidia` (vercel route + vite input + dev middleware, same wiring as `/openai`), membership doc [docs/nvidia-inception.md](docs/nvidia-inception.md) `→ /docs/nvidia-inception` + overview deck [docs/nvidia-inception/index.html](docs/nvidia-inception/index.html) `→ /docs/nvidia-inception/index.html`, free hosted-model map [docs/nvidia-models.md](docs/nvidia-models.md) `→ /docs/nvidia-models`, forum write-up [docs/nvidia-nemotron-spotlight.md](docs/nvidia-nemotron-spotlight.md) `→ /docs/nvidia-nemotron-spotlight`, tutorials [docs/tutorials/nvidia-3d-free.md](docs/tutorials/nvidia-3d-free.md) `→ /tutorials/nvidia-3d-free` and [docs/tutorials/nvidia-nim-self-host.md](docs/tutorials/nvidia-nim-self-host.md) `→ /tutorials/nvidia-nim-self-host`, engineering post [blog/image-to-3d-on-nvidia-l4-and-blackwell.html](blog/image-to-3d-on-nvidia-l4-and-blackwell.html) `→ /blog/image-to-3d-on-nvidia-l4-and-blackwell`, member badge [public/marks/nvidia-inception-badge.svg](public/marks/nvidia-inception-badge.svg) in [public/footer.html](public/footer.html), directory card in [pages/partners.html](pages/partners.html) `→ /partners` | Live | Everything NVIDIA on the platform, in two layers. **Free hosted lane:** one `NVIDIA_API_KEY` behind TRELLIS text-to-3D, FLUX.1-schnell, the Llama/Nemotron chat lineup, Nemotron vision, nv-embedqa, the reranker, NemoGuard, and Magpie speech (`nvidia-models`). **Self-hosted GPU fleet:** 12 Cloud Run GPU services, 11 on `nvidia-l4` and one on `nvidia-rtx-pro-6000` (Blackwell), covering text/image-to-3D, texture, remesh, rigging, and motion (see each `workers/model-*/README.md`). Membership was accepted July 2026 and is a startup program, not a partnership or an investment; the badge links to NVIDIA's startup program and must not imply endorsement. || Press kit (brand marks + media assets) | [pages/press/index.html](pages/press/index.html) `→ /press`, marks [public/brand/](public/brand), layout source [marketing/brand/](marketing/brand/README.md), renderer [scripts/render-brand-assets.mjs](scripts/render-brand-assets.mjs) `npm run build:brand-assets` | Live | The self-serve press surface: transparent-PNG marks (cube, horizontal and stacked lockups for dark and light grounds), the OpenAI announcement graphics, boilerplate at four lengths (one line, short, long, and a full-length bio) with copy buttons, fast facts, and the mark-usage rules. Everything is rendered from source rather than hand-exported, so a copy change re-renders the whole set; the renderer also builds `/brand/three-ws-press-kit.zip` with a README carrying the usage rules so the files cannot travel without them. Announcement cards come from [marketing/openai-select-partner/cards/social-card.html](marketing/openai-select-partner/cards/social-card.html) via `npm run build:openai-cards`. |diff --git a/data/changelog.json b/data/changelog.jsonindex fb719f0f6..8d1f792ec 100644--- a/data/changelog.json+++ b/data/changelog.json@@ -1,6 +1,16 @@{"$comment": "Curated changelog entries for three.ws, the editorial layer of the public changelog. New PAGE launches are tracked automatically via the `added` field in data/pages.json; this file is for everything else holders care about: improvements, fixes, SDK releases, trading/payments capabilities, security work. scripts/build-page-index.mjs merges both sources into CHANGELOG.md, public/changelog.json, and public/changelog.xml. Newest first. Allowed tags: feature, improvement, fix, sdk, infra, docs, security, desktop (desktop entries become the desktop app's release notes). `link` is optional and must be a live three.ws path.","entries": [+ {+ "date": "2026-10-24",+ "title": "Engine bridges are packaged for the Unity, Godot and Unreal stores",+ "summary": "One command, npm run package:engine-stores, validates the Unity, Godot and Unreal bridges and builds a reproducible upload package for each, with listing metadata and a submission checklist. The Unity package and Unreal plugin manifests now carry their documentation links.",+ "tags": [+ "sdk",+ "docs"+ ],+ "link": "/docs/engine-store-publishing"+ },{"date": "2026-10-24","title": "Drive the CLI from scripts and agents, and download a run report",diff --git a/data/pages.json b/data/pages.jsonindex df4cfc4a9..1436432ad 100644--- a/data/pages.json+++ b/data/pages.json@@ -6183,6 +6183,14 @@"priority": 0.6,"changefreq": "monthly"},+ {+ "path": "/docs/engine-store-publishing",+ "title": "Docs · Publishing the engine bridges",+ "description": "One command validates the Unity, Godot and Unreal bridges and builds a reproducible upload package for each store, with listing metadata and a submission checklist.",+ "added": "2026-10-24",+ "priority": 0.5,+ "changefreq": "monthly"+ },{"path": "/docs/remix","title": "Docs · The remix economy",diff --git a/docs/engine-store-listings/godot.json b/docs/engine-store-listings/godot.jsonnew file mode 100644index 000000000..a964738fe--- /dev/null+++ b/docs/engine-store-listings/godot.json@@ -0,0 +1,31 @@+{+ "price": "Free",+ "license": "Apache-2.0",+ "supportUrl": "https://three.ws",+ "documentationUrl": "https://three.ws/docs/engine-bridges",+ "sourceUrl": "https://github.com/nirholas/three.ws",+ "dataDisclosure": "The bridge sends the text prompt or reference image you submit to the public three.ws Forge API over HTTPS and downloads the finished .glb. It sends a random per-install client handle for rate limiting. It reads no project files other than the image you choose to submit, and sends no telemetry.",+ "releaseNotes": "0.1.0: first public release. Browse the catalog, generate a mesh from a text prompt or reference photos, poll the job, and import the result with the engine's own glTF importer, with collider, material and scale import settings.",+ "store": "Godot Asset Library",+ "productName": "three.ws Forge Bridge",+ "version": "0.1.0",+ "minEngine": "4.3",+ "tagline": "Text or photo to a textured 3D model, imported into your scene.",+ "description": "Generate a textured 3D model from a text prompt or reference photos with the free three.ws Forge pipeline and import it straight into the scene. The addon adds a three.ws Forge dock to the editor and a ThreeWsClient node for scripts. Downloads are imported with Godot's native GLTFDocument importer, so no third-party importer is needed. Import settings cover convex collision shapes, material import and uniform scale. A runnable example scene and a headless smoke test are included. Every call goes to the live public three.ws API.",+ "category": "Tools",+ "tags": [+ "3d",+ "ai",+ "gltf",+ "generative",+ "forge",+ "text-to-3d",+ "image-to-3d",+ "import"+ ],+ "submission": {+ "upload": "Asset Library > Submit Asset. Download provider: Custom. Download URL: the release asset URL of the packaged zip. Godot installs the zip contents into the project, so the archive holds addons/three_ws_bridge plus LICENSE and README.md.",+ "media": "Icon: a 128px or larger PNG URL (rendered at dist/engine-stores/godot/artwork). Add 2 or more screenshot URLs of the dock.",+ "godotVersionField": "4.3"+ }+}diff --git a/docs/engine-store-listings/unity.json b/docs/engine-store-listings/unity.jsonnew file mode 100644index 000000000..0a01aa07e--- /dev/null+++ b/docs/engine-store-listings/unity.json@@ -0,0 +1,31 @@+{+ "price": "Free",+ "license": "Apache-2.0",+ "supportUrl": "https://three.ws",+ "documentationUrl": "https://three.ws/docs/engine-bridges",+ "sourceUrl": "https://github.com/nirholas/three.ws",+ "dataDisclosure": "The bridge sends the text prompt or reference image you submit to the public three.ws Forge API over HTTPS and downloads the finished .glb. It sends a random per-install client handle for rate limiting. It reads no project files other than the image you choose to submit, and sends no telemetry.",+ "releaseNotes": "0.1.0: first public release. Browse the catalog, generate a mesh from a text prompt or reference photos, poll the job, and import the result with the engine's own glTF importer, with collider, material and scale import settings.",+ "store": "Unity Asset Store (Publisher Portal, Package category)",+ "productName": "three.ws Forge Bridge",+ "version": "0.1.0",+ "minEngine": "2021.3",+ "tagline": "Text or photo to a textured 3D model, imported into your scene.",+ "description": "Generate a textured 3D model from a text prompt or reference photos with the free three.ws Forge pipeline, and import it straight into the Unity Editor without leaving the project. The package adds a Window > three.ws > Forge Bridge editor window and a runtime importer. Downloads are handed to glTFast, Unity's own glTF importer, so there is no custom mesh parser to maintain. Import settings cover convex mesh colliders, material import and uniform scale. A runnable sample generates a mesh at runtime when you press Space. Every call goes to the live public three.ws API.",+ "category": "Tools/Utilities (3D)",+ "tags": [+ "3d",+ "ai",+ "gltf",+ "generative",+ "forge",+ "text-to-3d",+ "image-to-3d",+ "import"+ ],+ "submission": {+ "upload": "Asset Store Tools: open a Unity 2021.3 project containing packages/unity-bridge, Asset Store Tools > Package Upload, select the package folder, validate, upload.",+ "media": "Icon 160x100, card 420x280, cover 1950x1300, 5 or more screenshots. Base artwork is rendered at dist/engine-stores/unity/artwork.",+ "dependencies": "com.unity.cloud.gltfast 5.1.0 and com.unity.nuget.newtonsoft-json 3.2.1 resolve automatically through the Package Manager."+ }+}diff --git a/docs/engine-store-listings/unreal.json b/docs/engine-store-listings/unreal.jsonnew file mode 100644index 000000000..b9da2b41a--- /dev/null+++ b/docs/engine-store-listings/unreal.json@@ -0,0 +1,31 @@+{+ "price": "Free",+ "license": "Apache-2.0",+ "supportUrl": "https://three.ws",+ "documentationUrl": "https://three.ws/docs/engine-bridges",+ "sourceUrl": "https://github.com/nirholas/three.ws",+ "dataDisclosure": "The bridge sends the text prompt or reference image you submit to the public three.ws Forge API over HTTPS and downloads the finished .glb. It sends a random per-install client handle for rate limiting. It reads no project files other than the image you choose to submit, and sends no telemetry.",+ "releaseNotes": "0.1.0: first public release. Browse the catalog, generate a mesh from a text prompt or reference photos, poll the job, and import the result with the engine's own glTF importer, with collider, material and scale import settings.",+ "store": "Fab (Unreal Engine plugin)",+ "productName": "three.ws Forge Bridge",+ "version": "0.1.0",+ "minEngine": "5.3.0",+ "tagline": "Text or photo to a textured 3D model, imported with Interchange.",+ "description": "Generate a textured 3D model from a text prompt or reference photos with the free three.ws Forge pipeline, straight into the Unreal Editor. The plugin adds a Window > three.ws Forge Bridge dock with a prompt field, a quality tier and a Generate and import button. Downloads are imported through Unreal's own Interchange glTF pipeline, so there is no custom mesh parser. Import settings cover bounding-box collision, material import and scale. Includes a C++ client module usable from your own tools. Every call goes to the live public three.ws API.",+ "category": "Code Plugins",+ "tags": [+ "3d",+ "ai",+ "gltf",+ "interchange",+ "generative",+ "forge",+ "text-to-3d",+ "import"+ ],+ "submission": {+ "upload": "Fab Publisher Portal > Create listing > Code Plugin. Upload one build per supported engine version, produced with: RunUAT BuildPlugin -Plugin=<path>/ThreeWsBridge.uplugin -Package=<out> -TargetPlatforms=Win64+Linux. The packaged source zip in dist/engine-stores/unreal is the reviewable source for the listing.",+ "media": "Thumbnail 1920x1080 and 3 or more screenshots; icon 512x512 rendered at dist/engine-stores/unreal/artwork.",+ "note": "Unreal Editor is not installed on the packaging machine, so the binary build is the step that runs on the owner's Unreal install."+ }+}diff --git a/docs/engine-store-publishing.md b/docs/engine-store-publishing.mdnew file mode 100644index 000000000..079dd5192--- /dev/null+++ b/docs/engine-store-publishing.md@@ -0,0 +1,38 @@+# Publishing the engine bridges to the stores++The Unity, Godot and Unreal bridges ([overview](./engine-bridges.md)) are packaged and validated by one script. The owner submits the output to each store.++```sh+npm run package:engine-stores # build everything into dist/engine-stores+npm run package:engine-stores -- --check # validate only, write nothing+npm run package:engine-stores -- --only godot+```++The script exits 1 if any validation fails. Zips are deterministic: sorted entries, fixed timestamps, so the same source tree always gives the same SHA-256. Output:++| Path | Content |+|---|---|+| `dist/engine-stores/manifest.json` | Per bridge: version, zip name, bytes, SHA-256, file count, every check that passed or failed |+| `dist/engine-stores/<engine>/<zip>` | The upload artifact |+| `dist/engine-stores/<engine>/listing.json` | Store listing text, copied from `docs/engine-store-listings/<engine>.json` |+| `dist/engine-stores/<engine>/artwork/icon-{128,512}.png` | Base icons rendered from `public/favicon.svg` |++## What is validated++Per bridge: required files exist; version is `x.y.z` and the listing version and minimum engine version equal the engine's own manifest (`package.json`, `plugin.cfg` plus `project.godot`, `.uplugin`); the LICENSE is Apache-2.0; no en or em dash and no unfinished-work marker in any packaged text file; the listing has every required field, a tagline of at most 80 characters, a description of at least 200 characters, https links, and a data disclosure. Unity also requires `documentationUrl`, `changelogUrl`, `licensesUrl`, valid asmdefs and existing sample paths. Godot requires a complete `plugin.cfg` whose script exists. Unreal requires an integer `Version`, `DocsURL`, and a `Build.cs` for each module. Tests: `tests/package-engine-bridges.test.js`.++## Listing metadata++Edit `docs/engine-store-listings/{unity,godot,unreal}.json`. They carry name, tagline, description, category, tags, price (Free), license, links, the data disclosure and the store-specific upload steps. When a bridge version changes, bump the engine manifest and the listing together; the validator rejects a mismatch.++## Submission checklist++All three: be signed in to the owner's publisher account; run `npm run package:engine-stores`; confirm every line says PASS; take 3 to 5 real screenshots of the editor window generating a model.++- [ ] **Unity Asset Store.** Create a Publisher Portal product (Package). In a Unity 2021.3 project containing `packages/unity-bridge`, run Asset Store Tools > Package Upload, validate, upload. Fill the page from `unity/listing.json`. Media: icon 160x100, card 420x280, cover 1950x1300.+- [ ] **Godot Asset Library.** Create a GitHub release attaching `godot/three-ws-forge-bridge-godot-<version>.zip`. Asset Library > Submit Asset: provider Custom, download URL the release asset, Godot version 4.3, icon URL from `godot/artwork/icon-128.png` hosted anywhere stable, text from `godot/listing.json`.+- [ ] **Fab (Unreal).** Install Unreal 5.3 or later, run `RunUAT BuildPlugin -Plugin=<path>/packages/unreal-bridge/ThreeWsBridge.uplugin -Package=<out> -TargetPlatforms=Win64+Linux` once per supported engine version, create a Code Plugin listing in the Fab Publisher Portal, upload each build, fill the page from `unreal/listing.json`. After approval, set `MarketplaceURL` in the `.uplugin`.++## Honest limits++Unreal binaries need an Unreal install, so Fab's per-version build runs on the owner's machine. Unity and Godot submissions need no engine to be installed on a publisher's side beyond the Unity Editor for Asset Store Tools. Review times and approval are the stores' decision.diff --git a/package.json b/package.jsonindex e4203fc3c..93f0f55d8 100644--- a/package.json+++ b/package.json@@ -248,6 +248,7 @@"audit:pages": "node scripts/audit-page-index.mjs --strict","audit:meetup": "node scripts/meetup-audit.mjs","audit:docs": "node scripts/audit-docs.mjs",+ "package:engine-stores": "node scripts/package-engine-bridges.mjs","listings:build": "node scripts/listings.mjs --build","listings:check": "node scripts/listings.mjs --check","listings:verify": "node scripts/listings.mjs --verify",diff --git a/packages/unity-bridge/package.json b/packages/unity-bridge/package.jsonindex 4a9a8476c..6921aa342 100644--- a/packages/unity-bridge/package.json+++ b/packages/unity-bridge/package.json@@ -5,6 +5,9 @@"description": "Generate textured 3D models from a text prompt or reference photos with the free three.ws Forge pipeline, straight into the Unity Editor. Imports the result with glTFast, Unity's own glTF importer. No mock server: every call goes to the live public API documented in specs/ENGINE_BRIDGE.md.","unity": "2021.3","license": "Apache-2.0",+ "documentationUrl": "https://three.ws/docs/engine-bridges",+ "changelogUrl": "https://three.ws/changelog",+ "licensesUrl": "https://github.com/nirholas/three.ws/blob/main/packages/unity-bridge/LICENSE","author": {"name": "three.ws","url": "https://three.ws"diff --git a/packages/unreal-bridge/ThreeWsBridge.uplugin b/packages/unreal-bridge/ThreeWsBridge.upluginindex 49671bd40..7083a5025 100644--- a/packages/unreal-bridge/ThreeWsBridge.uplugin+++ b/packages/unreal-bridge/ThreeWsBridge.uplugin@@ -7,7 +7,7 @@"Category": "Importers","CreatedBy": "three.ws","CreatedByURL": "https://three.ws",- "DocsURL": "",+ "DocsURL": "https://three.ws/docs/engine-bridges","MarketplaceURL": "","SupportURL": "https://three.ws","EngineVersion": "5.3.0",diff --git a/scripts/package-engine-bridges.mjs b/scripts/package-engine-bridges.mjsnew file mode 100644index 000000000..45dfaea7c--- /dev/null+++ b/scripts/package-engine-bridges.mjs@@ -0,0 +1,236 @@+#!/usr/bin/env node+// Package and validate the Unity, Godot and Unreal engine bridges for their stores.+//+// node scripts/package-engine-bridges.mjs [--out dist/engine-stores] [--only unity|godot|unreal] [--check]+//+// Output per bridge: a deterministic .zip (sorted entries, fixed timestamps, so the same+// source tree always yields the same SHA-256), store artwork rendered from the platform+// favicon, and one entry in manifest.json with the hash, file list and validation results.+// Exit code 1 if any validation fails. Nothing is uploaded: the owner submits.++import { createHash } from 'node:crypto';+import { mkdirSync, readFileSync, readdirSync, rmSync, statSync, writeFileSync, existsSync } from 'node:fs';+import { dirname, join, relative, resolve, sep } from 'node:path';+import { fileURLToPath } from 'node:url';+import { zipSync } from 'fflate';+import sharp from 'sharp';++const ROOT = resolve(dirname(fileURLToPath(import.meta.url)), '..');+const FIXED_MTIME = Date.UTC(2026, 0, 1, 0, 0, 0);+const BANNED_DASH = new RegExp('[' + String.fromCharCode(0x2013, 0x2014) + ']');+const LEFTOVER = /\b(TODO|FIXME|XXX)\b|not implemented/i;+const TEXT_EXT = /\.(cs|gd|cpp|h|cfg|json|md|tscn|godot|uplugin|asmdef|cs|txt)$/i;++function readJson(p) {+ return JSON.parse(readFileSync(p, 'utf8'));+}++const BRIDGES = {+ unity: {+ dir: 'packages/unity-bridge',+ listing: 'docs/engine-store-listings/unity.json',+ zipBase: 'com.three-ws.forge-bridge',+ required: ['package.json', 'README.md', 'LICENSE', 'Runtime/ThreeWsClient.cs', 'Runtime/ThreeWsForgeImporter.cs', 'Editor/ThreeWsForgeWindow.cs'],+ manifest(dir) {+ const p = readJson(join(dir, 'package.json'));+ return { name: p.displayName, id: p.name, version: p.version, license: p.license, description: p.description, minEngine: p.unity };+ },+ extra(dir, v) {+ const p = readJson(join(dir, 'package.json'));+ for (const k of ['documentationUrl', 'changelogUrl', 'licensesUrl']) {+ if (!p[k]) v.fail(`package.json is missing "${k}" (Unity Package Manager shows it in the package details panel)`);+ }+ if (!/^\d+\.\d+\.\d+$/.test(p.version)) v.fail('package.json version is not semver x.y.z');+ if (!/^[a-z0-9-]+(\.[a-z0-9-]+)+$/.test(p.name)) v.fail('package name is not a valid reverse-DNS UPM name');+ const asmdefs = ['Runtime/ThreeWsBridge.Runtime.asmdef', 'Editor/ThreeWsBridge.Editor.asmdef'];+ for (const a of asmdefs) readJson(join(dir, a));+ for (const s of p.samples || []) if (!existsSync(join(dir, s.path))) v.fail(`sample path missing: ${s.path}`);+ },+ exclude: (rel) => false,+ },+ godot: {+ dir: 'packages/godot-bridge',+ listing: 'docs/engine-store-listings/godot.json',+ zipBase: 'three-ws-forge-bridge-godot',+ required: ['LICENSE', 'README.md', 'addons/three_ws_bridge/plugin.cfg', 'addons/three_ws_bridge/plugin.gd', 'addons/three_ws_bridge/three_ws_client.gd', 'addons/three_ws_bridge/forge_importer.gd'],+ manifest(dir) {+ const cfg = readFileSync(join(dir, 'addons/three_ws_bridge/plugin.cfg'), 'utf8');+ const get = (k) => (cfg.match(new RegExp(`^${k}="([^"]*)"`, 'm')) || [])[1];+ const feat = readFileSync(join(dir, 'project.godot'), 'utf8').match(/config\/features=PackedStringArray\("([\d.]+)"/);+ return { name: get('name'), id: 'three_ws_bridge', version: get('version'), license: 'Apache-2.0', description: get('description'), minEngine: feat ? feat[1] : null };+ },+ extra(dir, v) {+ const cfg = readFileSync(join(dir, 'addons/three_ws_bridge/plugin.cfg'), 'utf8');+ for (const k of ['name', 'description', 'author', 'version', 'script']) {+ if (!new RegExp(`^${k}="[^"]+"`, 'm').test(cfg)) v.fail(`plugin.cfg is missing ${k}`);+ }+ if (!existsSync(join(dir, 'addons/three_ws_bridge', (cfg.match(/^script="([^"]+)"/m) || [])[1] || '-'))) v.fail('plugin.cfg script file does not exist');+ },+ // The Asset Library installs only what is under addons/; the packaged zip is the addon, license and readme.+ include: (rel) => rel.startsWith('addons/') || rel === 'LICENSE' || rel === 'README.md',+ exclude: (rel) => rel.split('/').includes('.godot'),+ },+ unreal: {+ dir: 'packages/unreal-bridge',+ listing: 'docs/engine-store-listings/unreal.json',+ zipBase: 'ThreeWsBridge-unreal-source',+ required: ['ThreeWsBridge.uplugin', 'README.md', 'LICENSE', 'Source/ThreeWsBridge/ThreeWsBridge.Build.cs', 'Source/ThreeWsBridgeEditor/ThreeWsBridgeEditor.Build.cs'],+ manifest(dir) {+ const u = readJson(join(dir, 'ThreeWsBridge.uplugin'));+ return { name: u.FriendlyName, id: 'ThreeWsBridge', version: u.VersionName, license: 'Apache-2.0', description: u.Description, minEngine: u.EngineVersion };+ },+ extra(dir, v) {+ const u = readJson(join(dir, 'ThreeWsBridge.uplugin'));+ if (!Number.isInteger(u.Version)) v.fail('uplugin Version must be an integer');+ if (!u.DocsURL) v.fail('uplugin DocsURL is empty (Fab shows it on the listing)');+ for (const m of u.Modules || []) {+ const base = join(dir, 'Source', m.Name);+ if (!existsSync(join(base, `${m.Name}.Build.cs`))) v.fail(`module ${m.Name} has no Build.cs`);+ }+ },+ exclude: (rel) => /(^|\/)(Binaries|Intermediate|Saved)\//.test(rel),+ },+};++function makeValidator(label) {+ const result = { label, errors: [], checks: [] };+ return {+ result,+ pass: (m) => result.checks.push(m),+ fail: (m) => result.errors.push(m),+ };+}++function walk(dir, base = dir, out = []) {+ for (const name of readdirSync(dir).sort()) {+ const abs = join(dir, name);+ if (statSync(abs).isDirectory()) walk(abs, base, out);+ else out.push(relative(base, abs).split(sep).join('/'));+ }+ return out;+}++export function sha256(buf) {+ return createHash('sha256').update(buf).digest('hex');+}++export function listing(key) {+ return readJson(join(ROOT, BRIDGES[key].listing));+}++export function validateBridge(key) {+ const b = BRIDGES[key];+ const dir = join(ROOT, b.dir);+ const v = makeValidator(key);+ const meta = b.manifest(dir);+ for (const f of b.required) (existsSync(join(dir, f)) ? v.pass(`has ${f}`) : v.fail(`missing required file ${f}`));+ if (!meta.version) v.fail('no version found in the engine manifest');+ if (!meta.name) v.fail('no display name found in the engine manifest');+ if (!/^\d+\.\d+\.\d+$/.test(meta.version || '')) v.fail(`version "${meta.version}" is not x.y.z`);+ else v.pass(`version ${meta.version}`);+ if (existsSync(join(dir, 'LICENSE')) && !/Apache License/.test(readFileSync(join(dir, 'LICENSE'), 'utf8').slice(0, 400))) v.fail('LICENSE is not Apache-2.0 text');+ if (meta.license !== 'Apache-2.0') v.fail(`license in manifest is ${meta.license}, expected Apache-2.0`);+ b.extra(dir, v);++ let files = walk(dir).filter((r) => !b.exclude(r));+ if (b.include) files = files.filter(b.include);+ for (const rel of files) {+ if (!TEXT_EXT.test(rel) && !/^LICENSE$/.test(rel)) continue;+ const text = readFileSync(join(dir, rel), 'utf8');+ if (BANNED_DASH.test(text)) v.fail(`${rel} contains an en or em dash`);+ if (rel !== 'LICENSE' && LEFTOVER.test(text)) v.fail(`${rel} contains an unfinished-work marker`);+ }+ v.pass(`${files.length} files scanned`);++ const l = listing(key);+ const need = ['store', 'productName', 'version', 'tagline', 'description', 'category', 'tags', 'price', 'license', 'minEngine', 'supportUrl', 'documentationUrl', 'sourceUrl', 'dataDisclosure', 'releaseNotes', 'submission'];+ for (const k of need) if (l[k] == null || l[k] === '' || (Array.isArray(l[k]) && !l[k].length)) v.fail(`listing is missing "${k}"`);+ if (l.version !== meta.version) v.fail(`listing version ${l.version} differs from engine manifest ${meta.version}`);+ if (l.minEngine !== meta.minEngine) v.fail(`listing minEngine ${l.minEngine} differs from engine manifest ${meta.minEngine}`);+ if (l.tagline && l.tagline.length > 80) v.fail(`tagline is ${l.tagline.length} chars, limit 80`);+ if (l.description && l.description.length < 200) v.fail('description is under 200 chars');+ if (l.license !== meta.license) v.fail('listing license differs from engine manifest');+ for (const k of Object.keys(l)) if (BANNED_DASH.test(JSON.stringify(l[k]))) v.fail(`listing field ${k} contains an en or em dash`);+ for (const k of ['supportUrl', 'documentationUrl', 'sourceUrl']) if (l[k] && !/^https:\/\//.test(l[k])) v.fail(`${k} must be https`);+ if (!v.result.errors.length) v.pass('listing metadata matches the engine manifest');+ return { meta, files, dir, v, l };+}++export async function renderArtwork(outDir) {+ const svg = readFileSync(join(ROOT, 'public/favicon.svg'));+ mkdirSync(outDir, { recursive: true });+ const sizes = [128, 512];+ const out = [];+ for (const s of sizes) {+ const buf = await sharp(svg, { density: 384 }).resize(s, s).png({ compressionLevel: 9 }).toBuffer();+ const name = `icon-${s}.png`;+ writeFileSync(join(outDir, name), buf);+ out.push({ file: name, bytes: buf.length, sha256: sha256(buf) });+ }+ return out;+}++export function buildZip(key, info) {+ const entries = {};+ for (const rel of info.files) {+ entries[rel] = [readFileSync(join(info.dir, rel)), { mtime: FIXED_MTIME, level: 9 }];+ }+ const root = key === 'godot' ? '' : '';+ const ordered = Object.fromEntries(Object.keys(entries).sort().map((k) => [root + k, entries[k]]));+ return Buffer.from(zipSync(ordered));+}++export async function packageAll({ out = join(ROOT, 'dist/engine-stores'), only = null, write = true } = {}) {+ const keys = only ? [only] : Object.keys(BRIDGES);+ const manifest = { generatedFor: 'three.ws engine bridges', bridges: {} };+ let ok = true;+ if (write) {+ rmSync(out, { recursive: true, force: true });+ mkdirSync(out, { recursive: true });+ }+ for (const key of keys) {+ const info = validateBridge(key);+ const zip = buildZip(key, info);+ const zipName = `${BRIDGES[key].zipBase}-${info.meta.version}.zip`;+ const entry = {+ store: info.l.store,+ version: info.meta.version,+ zip: zipName,+ bytes: zip.length,+ sha256: sha256(zip),+ fileCount: info.files.length,+ validation: { passed: info.v.result.errors.length === 0, checks: info.v.result.checks, errors: info.v.result.errors },+ };+ if (write) {+ const d = join(out, key);+ mkdirSync(d, { recursive: true });+ writeFileSync(join(d, zipName), zip);+ writeFileSync(join(d, 'listing.json'), JSON.stringify(info.l, null, '\t') + '\n');+ entry.artwork = await renderArtwork(join(d, 'artwork'));+ }+ if (!entry.validation.passed) ok = false;+ manifest.bridges[key] = entry;+ }+ if (write) writeFileSync(join(out, 'manifest.json'), JSON.stringify(manifest, null, '\t') + '\n');+ return { ok, manifest, out };+}++async function main() {+ const args = process.argv.slice(2);+ const arg = (n) => (args.includes(n) ? args[args.indexOf(n) + 1] : null);+ const only = arg('--only');+ if (only && !BRIDGES[only]) {+ console.error(`unknown bridge "${only}", expected unity, godot or unreal`);+ process.exit(2);+ }+ const { ok, manifest, out } = await packageAll({ out: resolve(ROOT, arg('--out') || 'dist/engine-stores'), only, write: !args.includes('--check') });+ for (const [key, e] of Object.entries(manifest.bridges)) {+ console.log(`${e.validation.passed ? 'PASS' : 'FAIL'} ${key} (${e.store}) v${e.version} ${e.zip} ${e.bytes} bytes sha256 ${e.sha256}`);+ for (const c of e.validation.checks) console.log(` ok ${c}`);+ for (const er of e.validation.errors) console.log(` FAIL ${er}`);+ }+ if (!args.includes('--check')) console.log(`\nWrote ${out}`);+ process.exit(ok ? 0 : 1);+}++if (process.argv[1] && resolve(process.argv[1]) === fileURLToPath(import.meta.url)) await main();diff --git a/tests/package-engine-bridges.test.js b/tests/package-engine-bridges.test.jsnew file mode 100644index 000000000..26186a4ff--- /dev/null+++ b/tests/package-engine-bridges.test.js@@ -0,0 +1,39 @@+import { describe, it, expect } from 'vitest';+import { unzipSync } from 'fflate';+import { validateBridge, buildZip, sha256, listing } from '../scripts/package-engine-bridges.mjs';++const KEYS = ['unity', 'godot', 'unreal'];++describe('engine bridge store packaging', () => {+ for (const key of KEYS) {+ it(`${key}: validates with no errors`, () => {+ const info = validateBridge(key);+ expect(info.v.result.errors).toEqual([]);+ expect(info.meta.version).toBe(listing(key).version);+ });++ it(`${key}: zip is byte-identical across builds and holds the required files`, () => {+ const info = validateBridge(key);+ const a = buildZip(key, info);+ const b = buildZip(key, validateBridge(key));+ expect(sha256(a)).toBe(sha256(b));+ const names = Object.keys(unzipSync(new Uint8Array(a)));+ expect(names).toContain('LICENSE');+ expect(names).toEqual([...names].sort());+ });+ }++ it('godot zip carries only the addon, license and readme', () => {+ const names = Object.keys(unzipSync(new Uint8Array(buildZip('godot', validateBridge('godot')))));+ expect(names.every((n) => n.startsWith('addons/') || n === 'LICENSE' || n === 'README.md')).toBe(true);+ });++ it('every listing field respects the store limits', () => {+ for (const key of KEYS) {+ const l = listing(key);+ expect(l.tagline.length).toBeLessThanOrEqual(80);+ expect(l.description.length).toBeGreaterThanOrEqual(200);+ expect(l.price).toBe('Free');+ }+ });+});