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(studio): implement device-aware AR launch URL generation
nirholas51e07a4eecc4
diff --git a/api/3d/studio.js b/api/3d/studio.jsindex 54f631ac7..8edf09b0d 100644--- a/api/3d/studio.js+++ b/api/3d/studio.js@@ -31,7 +31,7 @@import { cors, wrap, method, json, error, readJson, rateLimited } from '../_lib/http.js';import { limits, clientIp } from '../_lib/rate-limit.js';-import { startForge, originFromReq, viewerUrl } from '../_mcp-studio/forge-client.js';+import { startForge, originFromReq, viewerUrl, arLaunchUrl } from '../_mcp-studio/forge-client.js';import { checkPromptSafety } from '../_mcp-studio/safety.js';import { resolveLogoPrompt } from '../_lib/forge-director-prompts.js';diff --git a/api/_mcp-studio/forge-client.js b/api/_mcp-studio/forge-client.jsindex 40126aea6..519057c16 100644--- a/api/_mcp-studio/forge-client.js+++ b/api/_mcp-studio/forge-client.js@@ -41,6 +41,14 @@ export function viewerUrl(base, glbUrl) {return `${base}/viewer?src=${encodeURIComponent(glbUrl)}`;}+// Device-aware "place it in your room" launcher (api/ar.js): Android gets a+// Scene Viewer intent, iOS a Quick Look launch page, desktop a WebGL fallback.+// One URL serves every device, which is exactly what a ChatGPT surface needs.+export function arLaunchUrl(base, glbUrl, title) {+ const t = title ? `&title=${encodeURIComponent(String(title).slice(0, 80))}` : '';+ return `${base}/api/ar?src=${encodeURIComponent(glbUrl)}${t}`;+}+function failure(code, message, extra = {}) {const e = new Error(message);e.code = code;